phpMyAdmin is a PHP-based front-end control panel that allows to simply handle your MySQL databases and users, review SQL activity, import and export database backups, run searches, and more.
Requirements for Installing phpMyAdmin on Ubuntu:
- A LAMP stack (Linux, Apache, MySQL, and PHP)
- PHP 5.2.0 or newer
- The PHP mysql or mysqli extensions
- MySQL 5.0.1 or newer
Step 1: Install phpMyAdmin from Ubuntu Packages
This is the recommended installation process for a production environment.
Step 2: Configure phpMyAdmin Package
After installing phpMyAdmin, you’ll be presented with the package configuration screen.
- Press the SPACE bar to place an “*” beside “apache2.” Press TAB to highlight “OK,” then hit ENTER.
- Select YES when asked about whether to Configure the database for phpmyadmin with dbconfig-common and hit enter to proceed.
- Enter your MySQL password when prompted and hit enter to proceed.
- Enter the password that you want to use to log into phpmyadmin, hit enter to proceed and confirm your password.
Step 3: Finish the Configuration of Apache
After the installation has completed, add phpmyadmin to the apache configuration.
sudo nano /etc/apache2/apache2.conf
Add the phpmyadmin config to the file.
sudo service apache2 restart
You’ll be able to then access phpmyadmin by going to your_ip_address/phpmyadmin.For example: http://127.0.0.1/phpmyadmin.Log in with the root user and the password you set for the phpMyAdmin application.
You may install phpmyadmin from source. This is not recommended for a production web server as you will need to install updates yourself.