The tutorial for compiling and installing phpMyAdmin on CentOS 8 Stream system is as follows:
First, make sure your CentOS 8 Stream system has the necessary software and dependencies installed. You can install them using the following command:
sudo dnf install httpd php php-mysqlnd php-json php-mbstring php-zip php-gd php-xml php-intl php-cli
Download the source code package of phpMyAdmin. You can visit the official website of phpMyAdmin (
) or use the following command to download:
wget
Unzip the source code package:
tar -zxvf phpMyAdmin-5.1.1-all-languages.tar.gz
Move the decompressed phpMyAdmin folder to the root directory of the web server:
sudo mv phpMyAdmin-5.1.1-all-languages /var/www/html/phpmyadmin
Create a configuration file for phpMyAdmin:
sudo cp /var/www/html/phpmyadmin/config.sample.inc.php /var/www/html/phpmyadmin/config.inc.php
Use a text editor to open the config.inc.php
file and modify the following content:
Set a random key for encrypting phpMyAdmin cookies:
$cfg['blowfish_secret'] = 'your_random_secret_key';
Add MySQL server configuration information:
$cfg['Servers'][$i]['host'] = 'localhost';$cfg['Servers'][$i]['port'] = '3306';$cfg['Servers'][$i]['auth_type'] = 'cookie';
Make appropriate modifications based on your MySQL server configuration.
Create a temporary storage directory for phpMyAdmin:
sudo mkdir /var/lib/php/session sudo chown -R apache:apache /var/lib/php/session
It is assumed that your web server is using Apache. If you use another web server, please change the user and group accordingly.
Restart the Apache service:
sudo systemctl restart httpd
Make sure the firewall is allowing HTTP and HTTPS traffic:
sudo firewall-cmd --permanent --add-service=httpsudo firewall-cmd --permanent --add-service=httpssudo firewall-cmd --reload
Open phpMyAdmin in your browser and log in using the credentials of the MySQL server. The above is the basic tutorial for compiling and installing phpMyAdmin on CentOS 8 Stream system. Please note that the specific configuration and parameters may vary according to your needs, and you can adjust them according to your own situation. Also, make sure to back up important files and configurations before performing any operations.
The above is the detailed content of Tutorial on compiling and installing phpMyAdmin on Centos8 stream system.. For more information, please follow other related articles on the PHP Chinese website!