Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have a new CentOS 6 server running PHP 5.3.2. The output of php -v shows

Unable to load dynamic library '/usr/lib64/php/modules/ - 
/usr/lib64/php/modules/ cannot open shared object file

I modified /etc/php.ini to include and and restarted httpd. I did install PDO and phpinfo.php shows pdo_sqllite installed?? How do I install pdo_mysql and rectify above warning message?

share|improve this question – quanta Dec 3 '11 at 3:28

2 Answers 2

up vote 10 down vote accepted

you have to install the library first.

yum install php-mysql 
share|improve this answer

My server Centos 6.3, PHP 5.4.8, Nginx.

I try to reindex my Magento website:

php -f indexer.php reindexall

And get error:

'The PDO extension is required for this adapter but the extension is not loaded'

Then I run:

pecl install pdo

yum install php-mysql

then, restart server

service nginx restart

Try to reindex Magento:

php -f indexer.php reindexall

It works :)

share|improve this answer
This is illegible. I can't tell how to format it properly, else I'd edit it. Please use code blocks for configuration files and console input/output so that there's a visual organization to the text in the answer. See Formatting Help – austinian Aug 21 at 5:29
Hi, I'm new in here and just wanna try to help the other has the same problem with Re-Index Magento on Centos 6.3, PHP 5.4.8, Nginx. So, pls do not vote down if you do not have the same problem and do not understand. Thanks. – Duc Nguyen Aug 23 at 2:44
This is a similar error to a different question. The question at hand is how to resolve the failure to load the pdo_mysql dll when is included in the php.ini file, not when you get the error 'The PDO extension is required for this adapter but the extension is not loaded'. Please keep answers on topic, and if you have the answer to a different question that hasn't been asked, please ask and then answer another question. You can feel free to link to this question as a related question, but it is not the same question. – austinian Aug 23 at 3:10

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.