Introduction
phpMyAdmin is a free and open-source tool designed to administer MySQL database management systems using a web interface. It provides a graphical user interface to perform various database management-related tasks.
In this guide, we will show how to install phpMyAdmin onAlmaLinux 8.
Prerequisites
Apache Web Server. First, make sure the Apache already installed on your server. For installation you can check our Apache web server installation guide.
MySQL. You also need MySQL. You can install it by following our guide.
PHP. To install PHP, you can check our PHP installation guide.
Installation guide
1. Install EPEL
Install EPEL release by running this command:
dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
2. Install REMI Repositories.
To install REMI, run this command:
dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm
3. Install Fedora-Autoloader Package
Next, install fedora-autoloader package:
dnf install http://rpms.remirepo.net/enterprise/8/remi/x86_64/php-fedora-autoloader-1.0.0-5.el8.remi.noarch.rpm
4. Install PhpMyAdmin
Now you can install phpMyAdmin by running the following:
dnf --enablerepo=remi install phpMyAdmin
5. Restart Apache Web Server
To enable new configurations, restart the Apache:
systemctl restart httpd
6. Modify Configurations File
By default access to phpMyAdmin only from the local IP is enabled. However, you can edit the configuration file and enable access from the specific IP.
To do so, open the configuration file:
vi /etc/httpd/conf.d/phpMyAdmin.conf
Find these lines:
Then add the following lines:
Require ip your_workstation_ip
It should look like here (write your IP instead of "your_workstation_ip"):
Then save the file and exit (pres "Esc", then type :wq and click "Enter").
After you modified the configuration file, make sure to restart the Apache:
systemctl restart httpd
7. Access PhpMyAdmin
To open phpMyAdmin, open your web browser and enter the URL in the following format:
server_ip/phpmyadmin
So you need to simply enter your server IP and /phpmyadmin.
After you enter this, you should see the phpMyAdmin login page on which you can enter MySQL user credentials:
That's all. Now you can manage databases via phpMyAdmin: