开发者

Apache, PHP and Percona Database

I have just upgraded MySQL 5.0 to Percona XtraDB 5.1. I had to yum remove all the mysql stuff first. Everything was working fine, until I restarted Apache and now I get:

Fatal error: Call to undefined function mysql_connect()

Any ideas? I have a feeling I removed 开发者_StackOverflow中文版some sort of mysql plugin for apache at the same time.


You need to install the php-mysql library. Depending on your distribution, this may have a slightly different name. Also, I was just experimenting with this on Ubuntu 11.04. Ended up going back to MySQL because PHP-MySQL wouldn't install without libmysqlcient16 which wouldn't install because it conflicted with percona. Hopefully, you don't run into the same problems that I did.


I use the following functional configuration with PHP and Percona on at least 150 servers:

Percona-Server-shared-55-5.5.30-rel30.2.509.rhel6.x86_64
Percona-Server-client-55-5.5.30-rel30.2.509.rhel6.x86_64
Percona-Server-server-55-5.5.30-rel30.2.509.rhel6.x86_64
Percona-Server-devel-55-5.5.30-rel30.2.509.rhel6.x86_64
Percona-Server-shared-compat-5.5.30-rel30.2.509.rhel6.x86_64

php-5.3.3-22.el6.x86_64
php-xml-5.3.3-22.el6.x86_64
php-cli-5.3.3-22.el6.x86_64
php-pdo-5.3.3-22.el6.x86_64
php-mcrypt-5.3.3-1.el6.x86_64
php-xmlrpc-5.3.3-22.el6.x86_64
php-common-5.3.3-22.el6.x86_64
php-mysql-5.3.3-22.el6.x86_64

As for the error libmysqlcient16.so is, resolvable by installing Percona-Server-shared-compat-[version].rpm.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜