phpMyAdmin is a GUI-based web app to manage your MySQL databases. It’s a very powerful tool to have but it’s also an unnecessary component that you don’t need to use if you are familiar with MySQL basic commands. What’s better, since it’s easy to put on and remove you can quickly install it when needed and uninstall it when finished.
How to install phpMyAdmin
Run the following commands first,
sudo apt-get update sudo apt-get install phpmyadmin
During the installation, phpMyAdmin will walk you through a basic configuration. Select apache2 as the web server when prompted.
Choose <Yes> when asked to configure database for phpMyAdmin with dbconfig-common.
Then put in the password for the MySQL database and password for phpMyAdmin.
That’s all you need to do.
Now, go to http://domain/phpmyadmin to access it. Use your MySQL credentials to log in.
How to uninstall phpMyAdmin
Once you’ve done your work, you can simply remove it from the server by running the following commands.
sudo dpkg -P phpmyadmin sudo rm -f /etc/apache2/conf.d/phpmyadmin.conf sudo service apache2 restart
Select <Yes> when asked to deconfigure database for phpMyAdmin with dbconfig-common.
And <Yes> again when asked to purge the database for phpMyAdmin.