Your PHP installation appears to be missing the MySQL ... After deleting and restarting from cpanel

I deleted everything in my directory to "start over" When I install wordpress it says : Your PHP installation appears to be missing the MySQL extension which is required by WordPress. I tried changing the php version but it makes no difference. here is a scrnsht of my home dir : is there somthing I'm missing. Also I had downloaded a full site backup b4 I deleted here's a scrsht of what the folders are :

what backup files should I use and how can I revert the website back to normal. thanks a lot

Topic deprecation mysql php hosting Wordpress

Category Web


You should never touch any files outside of the public_html folder. Public HTML folder is where your web server loads the website, and the outside of that folder contains system level stuff related to the hosting that are part of your account, and you should not mess with that.


This does not sound like you deleted "some files". Somehow you managed to remove a PHP extension. This can have one of two reasons:

  1. You deleted the needed .so file
  2. You removed it from PHP

When you have access to a CLI (Terminal), or a PHP page that contains phpinfo(), then you can hit php --ini to find your PHP ini file location. This also tells you which additional files are loaded. Search for extension_dir in your configs. Then search though the additional files for the mysql extension and make sure it points to the (relative) .so file. And finally make sure the .so file for your extension actually exists.

I assume you have access to a fully unmanaged VPS or similar. ProTip: Get a sysadmin to support you on this until you have a full understanding of what you are doing. Everybody is learning, but it normally is easier when you are looking someone over the shoulder.


You probably deleted some files your hosting provider needs. I would reach out to them for assistance.

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.