Issue
When you access the website, you see the following error:
Your PHP installation appears to be missing the MySQL extension which is required by WordPress.
Please check that themysqli
PHP extension is installed and enabled.
If you are unsure what these terms mean you should probably contact your host. If you still need help you can always visit the WordPress support forums.
Environment
- CloudLinux All
- PHP Selector
Solution
1- Follow the procedures in:
https://cloudlinux.zendesk.com/hc/en-us/articles/360014084800-PHP-Selector-Integration-with-cPanel
First thing you need to do is to verify that your accounts has PHP-FPM disabled on WHM > MultiPHP Manager page (locally for account and globally on the whole server) because PHP-FPM is incompatible with Cloudlinux components such as stated here:
https://docs.cloudlinux.com/limits/#compatibility-matrix
Second thing - verify that accounts has PHP Version set to "Inherited" on WHM > MultiPHP Manager page such as stated here:
https://docs.cloudlinux.com/php_selector/#cpanel
Please note that PHP Selector does not work when alt-php version is selected as system default in MultiPHP Manager. Only ea-php versions should be selected there.
Third thing - make sure that EasyApache4 profile is installed from Cloudlinux. If you are not sure - just select any from the list available on WHM > EasyApache4 page and provision it.
Once all of the above is good, you should be able to enable mysql (or mysqli) extension for all php versions in LVE manager. And users should be able to enable or disable these extensions in 'Select PHP Version' section of their control panel.
Then: CageFS > Enable All:
# /usr/sbin/cagefsctl --enable-all
If that does not help:
2- Upgrade to another php version ( alt-php74) and disabling and enabling the following set of extensions:
$ selectorctl --disable-user-extensions=mysql,mysqli,pdo_mysql --version=7.4 --user=USERNAME
$ selectorctl --enable-user-extensions=mysqlnd,nd_mysqli,nd_pdo_mysql --version=7.4 --user=USERNAME
If that does not help:
3- run the following command for the user:
cagefsctl --update-etc USERNAME && cagefsctl -m USERNAME
Comments
0 comments
Please sign in to leave a comment.