Nur Rony
Polyglot Programmer, DevOps and Forever Learner

How to: Setup phpMyAdmin with Apache2 on Ubuntu

How to: Setup phpMyAdmin with Apache2 on Ubuntu

phpMyAdmin is an free web software to work with MySQL on the web—it provides a convenient visual front end to the MySQL capabilities. I cant think MySQL installed without phpMyAdmin


I am assuming that you have a running Ubuntu 14.04 Server and Linux part have taken care of as well. The steps in this post require the user to have root privileges. If you do not have any root privilege then you can ask for it to your server administrator.

Installing phpMyAdmin with Apache2

The easiest way to install phpMyAdmin is through apt-get

sudo apt-get install -y phpmyadmin apache2-utils  

During the installation, phpMyAdmin will walk you through a basic configuration. Once the process starts up, follow these steps:

  • Select Apache2 for the server
  • Choose YES when asked about whether to Configure the database for phpmyadmin with dbconfig-common
  • Enter your MySQL password when prompted
  • Enter the password that you want to use to log into phpmyadmin
  • After the installation has completed, add phpmyadmin to the apache configuration.
sudo nano /etc/apache2/apache2.conf  

Add the phpmyadmin config to the file.

Include /etc/phpmyadmin/apache.conf 

Restart Apache2 server

sudo service apache2 restart  

You can then access phpmyadmin by going to http://youripaddress/phpmyadmin.

If you face any problem just give me a shout... to blow my eardrums!!! :-)