MysqlI Support => enabled Client API library version => 5.6.26 Active Persistent Links => 0 Inactive Persistent Links => 0 Active Links => 0 Client API header version => 5.5.44-MariaDB MYSQLI_SOCKET => /var/lib/mysql/mysql.sock
如上, php5.6我安装的是php56w-mysql, Client API header version和Mysql版本不一致,会提示如下错误:
1
Headers and client library minor version mismatch. Headers:50544 Library:50627
[mysql-connectors-community] name=MySQL Connectors Community baseurl=http://repo.mysql.com/yum/mysql-connectors-community/el/6/$basearch/ enabled=1 gpgcheck=1 gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
[mysql-tools-community] name=MySQL Tools Community baseurl=http://repo.mysql.com/yum/mysql-tools-community/el/6/$basearch/ enabled=1 gpgcheck=1 gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
# Enable to use MySQL 5.5 [mysql55-community] name=MySQL 5.5 Community Server baseurl=http://repo.mysql.com/yum/mysql-5.5-community/el/6/$basearch/ enabled=1 gpgcheck=1 gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
# Enable to use MySQL 5.6 [mysql56-community] name=MySQL 5.6 Community Server baseurl=http://repo.mysql.com/yum/mysql-5.6-community/el/6/$basearch/ enabled=0 gpgcheck=1 gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
# Note: MySQL 5.7 is currently in development. For use at your own risk. # Please read with sub pages: https://dev.mysql.com/doc/relnotes/mysql/5.7/en/ [mysql57-community-dmr] name=MySQL 5.7 Community Server Development Milestone Release baseurl=http://repo.mysql.com/yum/mysql-5.7-community/el/6/$basearch/ enabled=0 gpgcheck=1 gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
接下来
1
yum install mysql mysql-devel mysql-server
Mysql5.5已经安装完毕,下一步,安装php的mysql扩展
1 2 3
yum install php56w-mysql ;不幸的事故再次发生 Package 1:mariadb-libs-5.5.44-1.el7_1.x86_64 is obsoleted by mysql-community-libs-5.5.46-2.el6.x86_64 which is already installed
MysqlI Support => enabled Client API library version => 5.5.46 Active Persistent Links => 0 Inactive Persistent Links => 0 Active Links => 0 Client API header version => 5.5.44 MYSQLI_SOCKET => /var/run/mysqld/mysqld.sock