How to install PHPMyAdmin on CentOS 7.3 Server

CentOS Tutorial – Hello everyone, today we will learn about how to install PHPMyAdmin on CentOS 7.3 Server. As you know PHPMyAdmin is a great tool to administering MySQL or MariaDB Server. We can do many things to the database server such as user management, database management, table management, query editor and many more. Install PHPMyAdmin on CentOS is pretty easy since its available in EPEL Repository. So, we don’t have to manually install PHPMyAdmin.

Steps to install PHPMyAdmin on CentOS 7.3 Server

  1. Update CentOS
  2. Install LAMP Server
  3. Install EPEL Repository on CentOS
  4. Install PHPMyAdmin
  5. Configure PHPMyAdmin

Step 1. Update CentOS

It is recommended to update CentOS first prior to any other tasks. To update, use the following command

yum update

Step 2. Install LAMP Server

Please read the following tutorial to install LAMP Server on CentOS 7.3

Step 3. Install EPEL Repository on CentOS 7.3

To install EPEL on CentOS 7.3 server, use this command below

yum install epel-release

Step 4. Install PHPMyAdmin

Now use the following command to install phpmyadmin on CentOS

yum install phpmyadmin

Output:

...
Dependencies Resolved

========================================================================================================
 Package                             Arch           Version                          Repository    Size
========================================================================================================
Installing:
 phpMyAdmin                          noarch         4.4.15.10-2.el7                  epel         4.7 M
Installing for dependencies:
 compat-libtidy                      x86_64         0.99.0-37.20091203.el7           epel         133 k
 dejavu-fonts-common                 noarch         2.33-6.el7                       base          64 k
 dejavu-sans-fonts                   noarch         2.33-6.el7                       base         1.4 M
 fontpackages-filesystem             noarch         1.44-8.el7                       base         9.9 k
 libX11                              x86_64         1.6.3-3.el7                      base         606 k
 libX11-common                       noarch         1.6.3-3.el7                      base         162 k
 libXau                              x86_64         1.0.8-2.1.el7                    base          29 k
 libXpm                              x86_64         3.5.11-3.el7                     base          54 k
 libjpeg-turbo                       x86_64         1.2.90-5.el7                     base         134 k
 libpng                              x86_64         2:1.5.13-7.el7_2                 base         213 k
 libxcb                              x86_64         1.11-4.el7                       base         189 k
 libxslt                             x86_64         1.1.28-5.el7                     base         242 k
 php-bcmath                          x86_64         5.4.16-42.el7                    base          57 k
 php-fedora-autoloader               noarch         1.0.0-1.el7                      epel         9.6 k
 php-gd                              x86_64         5.4.16-42.el7                    base         127 k
 php-mbstring                        x86_64         5.4.16-42.el7                    base         505 k
 php-php-gettext                     noarch         1.0.12-1.el7                     epel          23 k
 php-process                         x86_64         5.4.16-42.el7                    base          55 k
 php-tcpdf                           noarch         6.2.13-1.el7                     epel         2.1 M
 php-tcpdf-dejavu-sans-fonts         noarch         6.2.13-1.el7                     epel         257 k
 php-tidy                            x86_64         5.4.16-7.el7                     epel          23 k
 php-xml                             x86_64         5.4.16-42.el7                    base         125 k
 t1lib                               x86_64         5.1.2-14.el7                     base         166 k

Transaction Summary
========================================================================================================
Install  1 Package (+23 Dependent packages)

Total download size: 11 M
Installed size: 49 M
Is this ok [y/d/N]:

Answer y and press Enter to start installing

Step 5. Configure PHPMyadmin

We need to change the IP address on the phpmyadmin configuration file.

nano /etc/httpd/conf.d/phpMyAdmin.conf

Now change any line that read Require ip 127.0.0.1 and Allow from 127.0.0.1 with your current workstation IP address. Please note that this is the IP address where you want to connect from. So, its not the server IP address:

. . .
Require ip your_workstation_IP_address
. . .
Allow from your_workstation_IP_address
. . .
Require ip your_workstation_IP_address
. . .
Allow from your_workstation_IP_address
. . .

Close and save the file. And then restart web server

systemctl restart httpd

Now open web browser from your workstation and type the CentOS IP address with the following format

http://ip_address/phpmyadmin

install PHPMyAdmin on CentOS 7.3

That’s it, that’s a simple way to install PHPMyAdmin on CentOS server.

 

Admin

Leave a Reply

Your email address will not be published. Required fields are marked *