Install phpMyAdmin in CentOS 7
The web interface of phpMyAdmin is now actively used by users of MySQL databases, because they interact only via the terminal. Installing additional software with a graphical interface will significantly simplify working with web servers, but it will first have to perform a range of activities, which sometimes cause difficulties. Today we would like as much detail as possible to consider the installation of phpMyAdmin in CentOS operating system 7, dividing all the important action steps. You only need to follow the instructions and correctly enter each command.
Install phpMyAdmin in CentOS 7
Unfortunately, the official repository of the application in question does not exist, so you have to first add the user store from which further and runs the installation process. In addition, at the moment, especially popular are the two versions of phpMyAdmin, we will tell you about installing each of them about the further configuration of the Apache web server or Nginx.
Adding phpMyAdmin
Of course, when working with a new application in Linux is always a priority is adding their libraries to the system, and phpMyAdmin is no exception. Let’s talk for a moment about the two available versions, starting with the recommended developers.
Install phpMyAdmin 4.4
4.4 phpMyAdmin works on PHP version 5.4, and as we know, this version is not the latest, that does not prevent her to be the most popular and in demand. Installation on CentOS is via the classic “Terminal” literally in a few steps:





If you are using a web server such as Apache, you will only have to restart it and check the operation of installed components by clicking on the address https://ip_вашего_сервера/phpmyadmin.
Install the latest version of phpMyAdmin
Some users are only interested in the latest version of phpMyAdmin to be installed where you will need to complete a few other actions that further downloading the new packages. In General, the instruction remains similar, but with some changes.




The addition of all components is complete, but before beginning work with the web interface you will need to configure the server. Next, we will examine the implementation of this procedure in two popular solutions Apache and Nginx.
Configuring phpMyAdmin with Nginx
Some users prefer to work with the Nginx web-server as that ensures high performance and throughput. If you are a supporter of this software, after installing phpMyAdmin you will have to make a number of settings to adjust performance of the whole mechanism.
Priority please note that the web server has already been added to the operating system, if not, alternately write in the console the following command:
sudo yum install epel-release
sudo yum install nginx
sudo systemctl start nginx
After that follow this instructions:





It is recommended to secure a web server by creating a random password. To do this, type openssl passwd and copy the result. Next, you will need to run the password file using sudo vi /etc/nginx/passwords and add there a new line in the format username:passwordto the result, for example, Admin:4B7fsek4L2.
Configure phpMyAdmin in Apache
Though the previous web server, and is better in some aspects, the Apache is still a very popular solution and is used in the software LAMP. Its installation in CentOS is done with just a few commands:
yum install httpd-y
systemctl start httpd.service
systemctl enable httpd.service
If the server is already added or you performed the above commands, you can go directly to the setting up phpMyAdmin, and this is done in the following way:


Options Indexes FollowSymLinks
AllowOverride All
AuthType Basic
AuthName “Restricted Content”
AuthUserFile /etc/httpd/passwords
Require valid-user

In this article, you were acquainted not only with the process of adding phpMyAdmin to the components themselves, but also learned about the initial setup in two different web servers. During execution, each command is strongly recommended to read the notices that appear in the console: they can sometimes indicate errors that need immediate solutions.