How to open phpmyadmin on azure linux

Pascal 20 Reputation points
2024-04-19T21:13:49.05+00:00

I installed lamp on azure vm but i cant open phpmyadin.I get this error when i try to connect using IP address i get this error "This site can’t be reached

102.133.169.103 refused to connect.

Try:

  • Checking the connection
  • [Checking the proxy and the firewall]

ERR_CONNECTION_REFUSED"

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,242 questions
0 comments No comments
{count} votes

Accepted answer
  1. Prrudram-MSFT 22,486 Reputation points
    2024-04-23T11:24:46.7866667+00:00

    @Pascal

    We noticed that you rated an answer as not helpful. I have provided an answer with the relevant details to make this a positive experience for you. Thanks!

    We value your feedback. If my answer is helpful, would you be so kind to re-evaluate your feedback, accept my answer and upvote the same please?

    Answer:

    By default, only SSH connections are allowed into Linux VMs deployed in Azure. Because this VM is going to be a web server, you need to open port 80 from the internet. Use the az vm open-port command to open the desired port.

    You can refer to this document for details https://learn.microsoft.com/en-us/azure/virtual-machines/linux/tutorial-lamp-stack

    If I have answered your query, please click "Accept as answer" as a token of appreciation

    0 comments No comments

4 additional answers

Sort by: Most helpful
  1. Deepanshu katara 5,370 Reputation points
    2024-04-20T05:51:31.78+00:00

    Hi,

    Here are some troubleshooting steps you can try:

    1. Check Apache and MySQL services: Ensure that Apache and MySQL services are running on your Azure VM. You can do this by SSH-ing into your VM and running commands like sudo systemctl status apache2 and sudo systemctl status mysql to check their statuses. If they're not running, start them using sudo systemctl start apache2 and sudo systemctl start mysql.
    2. If the website has been stopped and restarted you have to first connect to the website URL from a browser. Once you do that, the instance is running and you can connect to phpMyAdmin. It will launch without a login scree
    3. Ensure that PHP is installed and configured properly on your Azure VM. You can check the PHP configuration by creating a PHP file with <?php phpinfo(); ?> and accessing it via a web browser to see if PHP is running correctly.

    Kindly check and accept answer , if it helps, Thankyou

    0 comments No comments

  2. Dillon Silzer 54,746 Reputation points
    2024-04-20T06:10:16.6666667+00:00

    Hi Pascal,

    Ensure you have the necessary ports open on your Azure VM's Network Security Group (NSG):

    Go to the Resource Group > Find the NSG associated to the VM > go to Inbound security rules:

    User's image

    Ensure you have added a rule to allow port 80 and 443 (and any other port you may have configured on the server to allow traffic to the server).

    If this is helpful please accept answer.

    0 comments No comments

  3. Pascal 20 Reputation points
    2024-04-26T19:39:29.6266667+00:00

  4. Deepanshu katara 5,370 Reputation points
    2024-04-27T04:08:13.3433333+00:00

    Hi Pascal ,

    Issue --> How to open and access phpmyadmin on azure linux Machines

    Solution --> Please check and follow this "https://techcommunity.microsoft.com/t5/azure-database-for-mysql-blog/manage-an-azure-database-for-mysql-flexible-server-database-with/ba-p/3988214"

    Thanks!

    0 comments No comments