How do I install the pdo_mysql driver on Red Hat Enterprise Linux 6.1?
Posted
by
Will Martin
on Server Fault
See other posts from Server Fault
or by Will Martin
Published on 2011-11-14T22:39:05Z
Indexed on
2011/11/15
1:57 UTC
Read the original article
Hit count: 553
I have a RHEL box running PHP 5.3.3, which was installed using the binary packages provided by yum
. I have installed the php-pdo package:
# yum info php-pdo
Loaded plugins: product-id, rhnplugin, subscription-manager
Updating Red Hat repositories.
Installed Packages
Name : php-pdo
Arch : x86_64
Version : 5.3.3
Release : 3.el6_1.3
Size : 168 k
Repo : installed
From repo : rhel-x86_64-server-6
Summary : A database access abstraction module for PHP applications
URL : http://www.php.net/
License : PHP
Description : The php-pdo package contains a dynamic shared object that will add
: a database access abstraction layer to PHP. This module provides
: a common interface for accessing MySQL, PostgreSQL or other
: databases.
It appears to be working correctly for SQLite databases, but not MySQL. There's no file including pdo_mysql.so in /etc/php.d, and there is no copy of pdo_mysql.so in /usr/lib64/php/modules.
I'm pretty sure I just need the driver file and a line in the PHP configuration. A yum search pdo mysql
didn't turn up any useful packages, and Google has failed me. If I were on Ubuntu or Debian, I'd apt-get install php5-mysql
and be done with it.
So ... where in Red Hat land do I get a copy of pdo_mysql.so, and install it properly?
© Server Fault or respective owner