I have a CentOs 6.7 server. I have problem to make pdo_mysql available on apache2. following shows for Command line:
myserver$ php -m
PDO, pdo_mysql, pdo_sqlite
but phpinfo(), shows only PDO and pdo_sqlite
I already included following in php.ini
extension=pdo_mysql.so
extension=pdo.so
And restarted the Apache with:
sudo service httpd restart
It looks like, pdo_mysql is installed on a different php. when I search the server for pdo.so and pdo_mysql.so, I get pdo.so in three places, but pdo_mysql in two places.
myserver$ locate pdo.so
/usr/lib64/php/modules/pdo.so
/usr/lib64/php-zts/modules/pdo.so
/var/opt/remi/php56/root/usr/lib64/php/modules/pdo.so
myserver$ locate pdo_mysql.so
/usr/lib64/php/modules/pdo_mysql.so
/usr/lib64/php-zts/modules/pdo_mysql.so
And Apache installation in phpinfo() shows:
Loaded Configuration File /opt/remi/php56/root/etc/php.ini
So my recent php upgrade to php 5.6 is missing pdo_mysql. other php installation has it, but I don't know how to force the pdo_mysql installation to install it to /var/opt/remi/php56/
I used following for installing pdo-mysql:
yum install pdo-mysql
So, it installed it under /usr/lib64/php/
but not under /var/opt/remi/php56/
.