How to Install phpMyAdmin on CentOS 6.2 using EPEL Repository

phpmyadmin

PhpMyAdmin

phpMyAdmin is a free software tool written in PHP intended to handle the administration of MySQL over the World Wide Web. It can manage a whole MySQL server (needs a super-user) as well as a single database. phpMyAdmin supports a wide range of operations with MySQL. The most frequently used operations are supported by the user interface (managing databases, tables, fields, relations, indexes, users, permissions, etc), while you still have the ability to directly execute any SQL statement. In this post, i will show on how to install phpMyAdmin on CentOS 6.2 using EPEL repository. This post assumed that MySQL and Apache Httpd server has been installed and configured as per documented guidelines below :
How to Install Httpd on CentOS 6.2
How to Install MySQL Database Server on CentOS 6.2
How to Secure MySQL Database Server

See also  How to Install PHP with MySQL Support on CentOS 6.3

1. How to Install and Configure EPEL Repository :
Follow this steps to install and configure the Extra Packages for Enterprise Linux (EPEL) repository on CentOS 6.2. EPEL repository is another extra repository that creates, maintains, and manages a high quality set of additional packages for Enterprise Linux, including, but not limited to, Red Hat Enterprise Linux (RHEL) and CentOS server.

2. Simply run yum command to install phpmyadmin :

[root@centos62 ~]# yum install phpmyadmin -y
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.hostemo.com
 * epel: ftp.riken.jp
 * extras: mirrors.hostemo.com
 * updates: ossm.utm.my
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package phpMyAdmin.noarch 0:3.4.9-1.el6 will be installed
--> Processing Dependency: php-gd >= 5.2.0 for package: phpMyAdmin-3.4.9-1.el6.noarch
--> Processing Dependency: php-php-gettext for package: phpMyAdmin-3.4.9-1.el6.noarch
--> Running transaction check
---> Package php-gd.i686 0:5.3.3-3.el6_2.6 will be installed
---> Package php-php-gettext.noarch 0:1.0.11-3.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

====================================================================================================
 Package                    Arch              Version                      Repository          Size
====================================================================================================
Installing:
 phpMyAdmin                 noarch            3.4.9-1.el6                  epel               4.1 M
Installing for dependencies:
 php-gd                     i686              5.3.3-3.el6_2.6              updates            102 k
 php-php-gettext            noarch            1.0.11-3.el6                 epel                21 k

Transaction Summary
====================================================================================================
Install       3 Package(s)

Total download size: 4.2 M
Installed size: 15 M
Downloading Packages:
(1/3): php-gd-5.3.3-3.el6_2.6.i686.rpm                                       | 102 kB     00:00
(2/3): php-php-gettext-1.0.11-3.el6.noarch.rpm                               |  21 kB     00:00
(3/3): phpMyAdmin-3.4.9-1.el6.noarch.rpm                                     | 4.1 MB     00:46
----------------------------------------------------------------------------------------------------
Total                                                                89 kB/s | 4.2 MB     00:48
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : php-php-gettext-1.0.11-3.el6.noarch                                              1/3
  Installing : php-gd-5.3.3-3.el6_2.6.i686                                                      2/3
  Installing : phpMyAdmin-3.4.9-1.el6.noarch                                                    3/3

Installed:
  phpMyAdmin.noarch 0:3.4.9-1.el6

Dependency Installed:
  php-gd.i686 0:5.3.3-3.el6_2.6                php-php-gettext.noarch 0:1.0.11-3.el6

Complete!

3. Open the phpMyAdmin.conf configuration file as below :

[root@centos62 ~]# vi /etc/httpd/conf.d/phpMyAdmin.conf

Original phpMyAdmin.conf configuration file :

<Directory /usr/share/phpMyAdmin/>
Order Deny,Allow
Deny from All
Allow from 127.0.0.1
Allow from ::1
</Directory>

Change as below. Default setting only allows only localhost. Changes below will allow access to any ip address but very dangerous unless properly secured by SSL :

<Directory /usr/share/phpMyAdmin/>
Order Deny,Allow
Deny from All
Allow from All
Allow from ::1
</Directory>

4. Restart apache httpd service to take effect :

[root@centos62 ~]# service httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd:                                            [  OK  ]

5. Open PhpMyAdmin from myour browser using the following URL :

See also  How to Install Webmin 1.570 on CentOS 5.7 from tar.gz file

http://ipaddress/phpmyadmin/

How to Reset the Directory Manager Password on RHEL 7 / CentOS 7
How to Reset the Directory Manager Password on RHEL 7 / CentOS 7

It is best practice to remember passwords, but because too many passwords, sometimes we forget. We are not encouraged to write the password on any paper or share the password...

How to Find Big Files Size on Linux RHEL/CentOS
How to Find Big Files Size on Linux RHEL/CentOS

As the linux administrator, sometimes we have to identify which files are most take much space in the linux server resulting in low free space. Low disk space can also...

Why Linux users should worry about malware and what they can do about it
Why Linux users should worry about malware and what they can do about it

Don’t drop your guard just because you’re running Linux. Preventing the spread of malware and/or dealing with the consequences of infection are a fact of life when using computers. If...

How to Reset Forgotten Root Password on Linux RHEL 7 / CentOS 7
How to Reset Forgotten Root Password on Linux RHEL 7 / CentOS 7

This short howto will explain the steps to reset a lost root password or to reset a forgotten root password on Linux RHEL 7 or CentOS 7. Basically, we will...

How to Update CentOS or Upgrade CentOS to the Latest Version
How to Update CentOS or Upgrade CentOS to the Latest Version

Recently, the latest version of CentOS 7.3 was released. All users of CentOS 7.0, 7.1 and 7.2 can upgrade their system to the most recent. This quick guide will explain...

How to Change your WordPress Username, Nickname and Display Name in MySQL
How to Change your WordPress Username, Nickname and Display Name in MySQL

After you create an account log in WordPress, you may want to change your WordPress username, as appropriate or due to security reason. However, you can not do this from...

How to Enable SSH Root Login on Ubuntu 16.04
How to Enable SSH Root Login on Ubuntu 16.04

As what we wrote in the previous article on how to allow SSH root on Ubuntu 14.04, after installing a fresh new copy of Ubuntu 16.04 LTS, we find that...

How to Change UUID of Linux Partition on CentOS 7
How to Change UUID of Linux Partition on CentOS 7

UUID (Universally Unique IDentifier) should be unique and it is used to identify storage devices on a linux system. If you cloned a virtual machine from vCenter, the metadata containing...

Leave a Reply

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