phpMyAdmin is the graphical web-based database management tool for MySQL. phpMyAdmin is easy to use and provides most of the option’s to work and manage your MySQL server. It also provides an easy way to set up database replication between multiple MySQL hosts with easy step wizard.
This article will help you to install phpMyAdmin in Ubuntu systems using the apt package manager. To install phpMyAdmin on CentOS, Redhat and Fedora refer below link.
Step 1 – Install LAMP Stack
We assume you already have installed LAMP on your system. If you do not have installed, Use the following command to install it. Below command will install Apache2, PHP5 and MySQL server in your Ubuntu, Debian and LinuxMint systems.
sudo apt-get update sudo apt-get install apache2 php mysql-server
Step 2 – Install phpMyAdmin
After installing LAMP stack on your system, let’s install phpMyAdmin using the command in your Ubuntu system.
sudo apt-get install phpmyadmin
During installation it will prompt for selecting web server, you have installed on your system. Select appropriate web server you used.
Step 3 – Configure Apache2 for phpMyAdmin
The installer creates and an Apache configuration file /etc/phpmyadmin/apache.conf for phpMyAdmin. Also, create a soft link to be used by Apache. Make sure a soft link is created at /etc/apache2/conf-available/phpmyadmin.conf. In case a soft link is not created and enable phpMyAdmin.
sudo ln -s /etc/phpmyadmin/apache.conf /etc/apache2/conf-available/phpmyadmin.conf sudo a2enconf phpmyadmin
After updating the above entry, restart Apache2 service using the following command
sudo service apache2 restart
Step 4 – Access phpMyAdmin
You phpMyAdmin installation has been completed successfully. Open you favourite web browser and access following url to open phpMyAdmin, change the localhost with servers hostname or ip address.
Using single phpMyAdmin we can manage multiple MySQL servers by adding multiple remote MySQL server. Use this article to add multiple MySQL hosts in phpMyAdmin.