The error message "ERROR: MySQL.so is not found. Please install alt-phpXX-mariadb106 package" indicates that a required PHP extension for MySQL (MySQL.so) is not available in the current PHP installation.
To resolve this issue, you'll need to install the appropriate PHP extension for MySQL. Since the error message mentions alt-phpXX-mariadb106
, it seems like you're using an alternative PHP version provided by cPanel's EasyApache.
Here are the steps you can take to fix this:
-
Identify the PHP Version:
Determine the PHP version you're using. Replace
XX
inalt-phpXX-mariadb106
with the actual PHP version (e.g.,alt-php74-mariadb106
for PHP 7.4). -
Install the Required Package:
Use the package manager for your system (like
yum
for CentOS) to install the PHP extension. For example:bash
-
yum install alt-phpXX-mariadb106-mysql
Replace
XX
with the appropriate PHP version. -
Restart Apache:
After installing the PHP extension, you'll need to restart Apache for the changes to take effect:
bash -
systemctl restart httpd
-
Verify the Extension:
To confirm that the extension is now available, you can check the list of loaded PHP extensions using the
php -m
command:bash
-
php -m | grep mysql
You should see
mysql
or similar extensions listed. -
Test Your Application:
Finally, test your application to ensure that it can now connect to the MySQL database without encountering the previous error.
If you're not using an alternative PHP version or if you're using a different PHP management system, the steps may vary. Please provide more details about your environment if you need further assistance.