php-mysql版本与Mysql服务器冲突 [英] php-mysql version conflicts with Mysql server

查看:114
本文介绍了php-mysql版本与Mysql服务器冲突的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我安装了php 5.3和mysql服务器5.5.我需要安装php-mysql,但是遇到了以下冲突.我该如何解决?

yum install php-mysql
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.versaweb.com
 * elrepo: elrepo.org
 * extras: yum.phx.singlehop.com
 * updates: yum.phx.singlehop.com
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-mysql.x86_64 0:5.3.3-3.el6_2.8 will be installed
--> Processing Dependency: php-common = 5.3.3-3.el6_2.8 for package: php-mysql-5.3.3-3.el6_2.8.x86_64
--> Processing Dependency: libmysqlclient.so.16(libmysqlclient_16)(64bit) for package: php-mysql-5.3.3-3.el6_2.8.x86_64
--> Processing Dependency: libmysqlclient.so.16()(64bit) for package: php-mysql-5.3.3-3.el6_2.8.x86_64
--> Running transaction check
---> Package mysql-libs.x86_64 0:5.1.61-1.el6_2.1 will be installed
---> Package php-common.x86_64 0:5.3.3-3.el6_2.5 will be updated
--> Processing Dependency: php-common = 5.3.3-3.el6_2.5 for package: php-5.3.3-3.el6_2.5.x86_64
--> Processing Dependency: php-common = 5.3.3-3.el6_2.5 for package: php-cli-5.3.3-3.el6_2.5.x86_64
--> Processing Dependency: php-common = 5.3.3-3.el6_2.5 for package: php-pdo-5.3.3-3.el6_2.5.x86_64
---> Package php-common.x86_64 0:5.3.3-3.el6_2.8 will be an update
--> Running transaction check
---> Package php.x86_64 0:5.3.3-3.el6_2.5 will be updated
---> Package php.x86_64 0:5.3.3-3.el6_2.8 will be an update
---> Package php-cli.x86_64 0:5.3.3-3.el6_2.5 will be updated
---> Package php-cli.x86_64 0:5.3.3-3.el6_2.8 will be an update
---> Package php-pdo.x86_64 0:5.3.3-3.el6_2.5 will be updated
---> Package php-pdo.x86_64 0:5.3.3-3.el6_2.8 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

===============================================================================================================================================================================================
 Package                                       Arch                                      Version                                              Repository                                  Size
===============================================================================================================================================================================================
Installing:
 php-mysql                                     x86_64                                    5.3.3-3.el6_2.8                                      updates                                     79 k
Installing for dependencies:
 mysql-libs                                    x86_64                                    5.1.61-1.el6_2.1                                     updates                                    1.2 M
Updating for dependencies:
 php                                           x86_64                                    5.3.3-3.el6_2.8                                      updates                                    1.1 M
 php-cli                                       x86_64                                    5.3.3-3.el6_2.8                                      updates                                    2.2 M
 php-common                                    x86_64                                    5.3.3-3.el6_2.8                                      updates                                    522 k
 php-pdo                                       x86_64                                    5.3.3-3.el6_2.8                                      updates                                     73 k

Transaction Summary
===============================================================================================================================================================================================
Install       2 Package(s)
Upgrade       4 Package(s)

Total size: 5.2 M
Is this ok [y/N]: y
Downloading Packages:
Running rpm_check_debug
Running Transaction Test


Transaction Check Error:
  file /usr/share/mysql/charsets/Index.xml from install of mysql-libs-5.1.61-1.el6_2.1.x86_64 conflicts with file from package MySQL-server-5.5.20-1.linux2.6.x86_64
  file /usr/share/mysql/charsets/README from install of mysql-libs-5.1.61-1.el6_2.1.x86_64 conflicts with file from package MySQL-server-5.5.20-1.linux2.6.x86_64

我建议从 http:下载shared-compat程序包: //dev.mysql.com/并用它替换默认的mysql-libs. shared-compat提供所有版本的MySQL客户端库,并且应满足将来的任何软件升级或安装要求.例如,使用名为MySQL-shared-compat-5.5.24-1.el6.x86_64.rpm

的软件包

要安装它,请删除现有的mysql-libs软件包,同时忽略rpm -e --nodeps mysql-libs的任何依赖关系,然后立即使用rpm -ihv MySQL-shared-compat-5.5.24-1.el6.x86_64.rpm安装新软件包.

如果服务器正在处理任何生产流量,那么您当然应该安排维护窗口,因为在安装新库之前,删除库可能会导致错误.

稍后,您还应该考虑将服务器和客户端程序包也替换为官方程序包,以避免使用来自不同供应商的版本.

I have php 5.3 and mysql server 5.5 installed. I need to install php-mysql, but got the following conflict. How do I resolve this?

yum install php-mysql
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.versaweb.com
 * elrepo: elrepo.org
 * extras: yum.phx.singlehop.com
 * updates: yum.phx.singlehop.com
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-mysql.x86_64 0:5.3.3-3.el6_2.8 will be installed
--> Processing Dependency: php-common = 5.3.3-3.el6_2.8 for package: php-mysql-5.3.3-3.el6_2.8.x86_64
--> Processing Dependency: libmysqlclient.so.16(libmysqlclient_16)(64bit) for package: php-mysql-5.3.3-3.el6_2.8.x86_64
--> Processing Dependency: libmysqlclient.so.16()(64bit) for package: php-mysql-5.3.3-3.el6_2.8.x86_64
--> Running transaction check
---> Package mysql-libs.x86_64 0:5.1.61-1.el6_2.1 will be installed
---> Package php-common.x86_64 0:5.3.3-3.el6_2.5 will be updated
--> Processing Dependency: php-common = 5.3.3-3.el6_2.5 for package: php-5.3.3-3.el6_2.5.x86_64
--> Processing Dependency: php-common = 5.3.3-3.el6_2.5 for package: php-cli-5.3.3-3.el6_2.5.x86_64
--> Processing Dependency: php-common = 5.3.3-3.el6_2.5 for package: php-pdo-5.3.3-3.el6_2.5.x86_64
---> Package php-common.x86_64 0:5.3.3-3.el6_2.8 will be an update
--> Running transaction check
---> Package php.x86_64 0:5.3.3-3.el6_2.5 will be updated
---> Package php.x86_64 0:5.3.3-3.el6_2.8 will be an update
---> Package php-cli.x86_64 0:5.3.3-3.el6_2.5 will be updated
---> Package php-cli.x86_64 0:5.3.3-3.el6_2.8 will be an update
---> Package php-pdo.x86_64 0:5.3.3-3.el6_2.5 will be updated
---> Package php-pdo.x86_64 0:5.3.3-3.el6_2.8 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

===============================================================================================================================================================================================
 Package                                       Arch                                      Version                                              Repository                                  Size
===============================================================================================================================================================================================
Installing:
 php-mysql                                     x86_64                                    5.3.3-3.el6_2.8                                      updates                                     79 k
Installing for dependencies:
 mysql-libs                                    x86_64                                    5.1.61-1.el6_2.1                                     updates                                    1.2 M
Updating for dependencies:
 php                                           x86_64                                    5.3.3-3.el6_2.8                                      updates                                    1.1 M
 php-cli                                       x86_64                                    5.3.3-3.el6_2.8                                      updates                                    2.2 M
 php-common                                    x86_64                                    5.3.3-3.el6_2.8                                      updates                                    522 k
 php-pdo                                       x86_64                                    5.3.3-3.el6_2.8                                      updates                                     73 k

Transaction Summary
===============================================================================================================================================================================================
Install       2 Package(s)
Upgrade       4 Package(s)

Total size: 5.2 M
Is this ok [y/N]: y
Downloading Packages:
Running rpm_check_debug
Running Transaction Test


Transaction Check Error:
  file /usr/share/mysql/charsets/Index.xml from install of mysql-libs-5.1.61-1.el6_2.1.x86_64 conflicts with file from package MySQL-server-5.5.20-1.linux2.6.x86_64
  file /usr/share/mysql/charsets/README from install of mysql-libs-5.1.61-1.el6_2.1.x86_64 conflicts with file from package MySQL-server-5.5.20-1.linux2.6.x86_64

解决方案

I suggest downloading a shared-compat package from http://dev.mysql.com/ and replacing the default mysql-libs with that. shared-compat provides all versions of MySQL client libraries and it should satisfy any future software upgrades or installations. For example use the package called MySQL-shared-compat-5.5.24-1.el6.x86_64.rpm

To install it, remove the existing mysql-libs package while ignoring any dependencies with rpm -e --nodeps mysql-libs and immediately install the new package with rpm -ihv MySQL-shared-compat-5.5.24-1.el6.x86_64.rpm.

You should of course schedule a maintenance window if the server is handling any production traffic as removing the libraries may cause errors before the new ones are installed.

Later you should also think about replacing the server and client packages to the official ones too to avoid having builds from different vendors.

这篇关于php-mysql版本与Mysql服务器冲突的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆