26.5 C
Senior Writer and partner

Install the latest PHPMyAdmin on CentOS 8

For developers, the application database is important. And many projects use MySQL or MariaDB to meet this need. In this sense, an application that helps the data query and the administration of the MySQL or MariaDB instance becomes necessary. In this post, I will help you to install maybe one of the most popular ones there is, I mean PHPMyAdmin on CentOS 8

PHPMyAdmin is an open-source application created in PHP that provides the administration of a MySQL or MariaDB database from a comfortable web interface. It is simply installed on the server, we make a few small configurations and that’s it. That’s it. Without consuming many resources you will have a quality application.

So, let’s get started.

Install the latest PHPMyAdmin on CentOS 8

Despite being one of the most popular tools available for the administration of MariaDB / MySQL it is not in the CentOS 8 repositories. However, it is possible to get the latest version thanks to the REMI repository.

- Advertisement -

So, let’s go for it.

Note: All the commands will be performed as the root user. In case your user has sudo access, you can use it before executing each command.

Open a terminal and add the EPEL repository.

dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

After it is added, the REMI repository must be added.

dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm

Now the next step is to disable the PHP 7.2 module which is the default in the CentOS 8 installation

dnf module reset php:7.2

And now enable the PHP 7.4 module of the REMI module.

dnf module enable php:remi-7.4

The next steps are to set up LAMP or LEMP on CentOS 8. This is up to you and the server you will be using.

For this example, I will install Apache.

dnf install httpd php-session php-json php-hash php-ctype php-mbstring php-zip php-gd php-curl php-openssl php-xml mariadb-server

And finally, it installs PHPMyAdmin

dnf --enablerepo=remi install phpMyAdmin
1.- Install the latest of PHPMyAdmin on CentOS 8
1.- Install the latest of PHPMyAdmin on CentOS 8

For PHPMyAdmin to run with Apache it is necessary to make a small change in the configuration file

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

And in the section leave it this way:

<Directory /usr/share/phpMyAdmin>
    AddDefaultCharset UTF-8
    Require all granted
2.- Configuring PHPMyAdmin before the first use
2.- Configuring PHPMyAdmin before the first use

Save the changes and close the editor.

To apply the changes in Apache, just restart the service

sudo systemctl restart httpd

Then, open a web browser and go to http://your-server/phpmyadmin and you will see the following screen:

3.- PHPMyAdmin main screen
3.- PHPMyAdmin main screen

So, enjoy it.

- Advertisement -
Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
"The best Linux newsletter on the web"


Please enter your comment!
Please enter your name here

Latest article