Submitted by john.tilghman@g... on Thu, 10/29/2009 - 23:27
I am running CentOS v5.3. After I install and update it is now at 5.4.
At this point I am trying to restore my sites from my crashed server.
The sites with wordpress restore fine, but when you go to the site I get
"Your PHP installation appears to be missing the MySQL extension which is required by WordPress."
But when I do an rpm -qa|grep -i php the rpm looks like its there.
I do not know what to do.
JT
Status:
Closed (fixed)
Comments
There are a few reasons the module might not be loading.
What execution type are you using for PHP? (mod_fcgid, cgi, or mod_php?) This will determine where configuration occurs.
Is there an /etc/php.d/mysql.ini file? This is usually included by the main php.ini, and loads the mysql PHP module.
Submitted by john.tilghman@g... on Fri, 10/30/2009 - 17:08 Comment #2
I do not know what wordpress uses. This wordpress was installed using the "Install Scripts", v2.4.8
Is there an /etc/php.d/mysql.ini file? Yes, here is the contents.
extension=mysql.so
Submitted by andreychek on Fri, 10/30/2009 - 19:53 Comment #3
Are you seeing errors in the error_log of that Virtual Server? That would be located in $HOME/logs/error_log.
Submitted by john.tilghman@g... on Fri, 10/30/2009 - 21:53 Comment #4
Nothing in the log, just an error about robot.txt.
Submitted by andreychek on Fri, 10/30/2009 - 21:58 Comment #5
Is the extention_dir setting by chance pointing to an invalid directory?
In $HOME/etc/php.ini, make sure extension_dir isn't being set. Also, if it's being set in the php,ini file under /etc/, make sure it's pointing at the correct place.
Submitted by JamieCameron on Sat, 10/31/2009 - 00:02 Comment #6
Yeah, the extension_dir is often set wrong - I've seen it set to /usr/lib64/php when it should be /usr/lib/php or vice-versa, due to a migration from 32 to 64-bit systems.
Submitted by john.tilghman@g... on Sat, 10/31/2009 - 08:13 Comment #7
$HOME/etc/php.ini is being set to extension_dir = "/usr/lib/php/modules"
/etc/php.ini is being set to extension_dir = "/usr/lib64/php/modules"
But this is CentOS v5.3 x86_64, so isn't this correct ?
JT
Submitted by john.tilghman@g... on Sat, 10/31/2009 - 08:20 Comment #8
looks like if $HOME/etc/php.ini is set this way extension_dir = "/usr/lib64/php/modules" , then it works.
When I do the restore of the site from the backup it resets it back to $HOME/etc/php.ini is set this way extension_dir = "/usr/lib/php/modules", which is STRANGE since it was a CentOS v5.3 x86_64 that this backup came from.
And all the sites worked there.
JT
Submitted by JamieCameron on Sat, 10/31/2009 - 16:24 Comment #9
Ok, the incorrect extension_dir seems to be the cause.
I will have Virtualmin correct that path when restoring a domain in the next release, so that this doesn't happen again..
Submitted by john.tilghman@g... on Sun, 11/01/2009 - 10:00 Comment #10
Sweet. You guys are the BEST...