将 MySQL 5.5 升级到 5.6 CentOS 6.6 时出错

将 MySQL 5.5 升级到 5.6 CentOS 6.6 时出错

我希望将 MySQL 5.5 升级到 5.6在我的CentOS 6.6服务器yum update mysql根据以下输出,我在命令后收到错误。

我正在按照指南进行操作这里。我还尝试使用进一步的故障排除指南来纠正该问题这里,遗憾的是这并没有解决问题。

错误输出

Error: Package: php-mysql-5.4.45-14.el6.remi.x86_64 (@remi)
           Requires: libmysqlclient.so.18(libmysqlclient_16)(64bit)
           Removing: mysql-libs-5.5.60-1.el6.remi.x86_64 (@remi)
               libmysqlclient.so.18(libmysqlclient_16)(64bit)
           Obsoleted By: mysql-community-libs-5.6.40-2.el6.x86_64 (mysql56-community)
               Not found

详细输出

yum update mysql
Loaded plugins: fastestmirror
Setting up Update Process
Loading mirror speeds from cached hostfile
epel/metalink                                            |  32 kB     00:00
 * epel: ftp.uni-stuttgart.de
 * remi-safe: mirror.23media.de
CityFan                                                  | 2.9 kB     00:00
PLESK_17_8_11-extras                                     | 2.9 kB     00:00
PLESK_17_PHP52                                           | 2.9 kB     00:00
PLESK_17_PHP53                                           | 2.9 kB     00:00
PLESK_17_PHP54                                           | 2.9 kB     00:00
PLESK_17_PHP55                                           | 2.9 kB     00:00
PLESK_17_PHP56                                           | 2.9 kB     00:00
PLESK_17_PHP70                                           | 2.9 kB     00:00
base                                                     | 3.7 kB     00:00
extras                                                   | 3.4 kB     00:00
mysql-connectors-community                               | 2.5 kB     00:00
mysql-tools-community                                    | 2.5 kB     00:00
mysql56-community                                        | 2.5 kB     00:00
plesk-migrator                                           | 2.9 kB     00:00
plesk-migrator-tp                                        | 2.9 kB     00:00
remi-safe                                                | 2.9 kB     00:00
updates                                                  | 3.4 kB     00:00
Resolving Dependencies
--> Running transaction check
---> Package mysql.x86_64 0:5.5.60-1.el6.remi will be obsoleted
--> Processing Dependency: real-mysql(x86-64) = 5.5.60-1.el6.remi for package: mysql-server-5.5.60-1.el6.remi.x86_64
---> Package mysql-community-client.x86_64 0:5.6.40-2.el6 will be obsoleting
--> Processing Dependency: mysql-community-libs(x86-64) >= 5.6.10 for package: mysql-community-client-5.6.40-2.el6.x86_64
--> Running transaction check
---> Package mysql-community-libs.x86_64 0:5.6.40-2.el6 will be obsoleting
--> Processing Dependency: mysql-community-common(x86-64) >= 5.6.10 for package: mysql-community-libs-5.6.40-2.el6.x86_64
---> Package mysql-community-server.x86_64 0:5.6.40-2.el6 will be obsoleting
--> Processing Dependency: libnuma.so.1(libnuma_1.2)(64bit) for package: mysql-community-server-5.6.40-2.el6.x86_64
--> Processing Dependency: libnuma.so.1(libnuma_1.1)(64bit) for package: mysql-community-server-5.6.40-2.el6.x86_64
--> Processing Dependency: libnuma.so.1()(64bit) for package: mysql-community-server-5.6.40-2.el6.x86_64
---> Package mysql-libs.x86_64 0:5.5.60-1.el6.remi will be obsoleted
--> Processing Dependency: libmysqlclient.so.18(libmysqlclient_16)(64bit) for package: php-mysql-5.4.45-14.el6.remi.x86_64
---> Package mysql-server.x86_64 0:5.5.60-1.el6.remi will be obsoleted
--> Running transaction check
---> Package mysql-community-common.x86_64 0:5.6.40-2.el6 will be installed
---> Package mysql-libs.x86_64 0:5.5.60-1.el6.remi will be obsoleted
--> Processing Dependency: libmysqlclient.so.18(libmysqlclient_16)(64bit) for package: php-mysql-5.4.45-14.el6.remi.x86_64
---> Package numactl.x86_64 0:2.0.9-2.el6 will be installed
--> Finished Dependency Resolution
Error: Package: php-mysql-5.4.45-14.el6.remi.x86_64 (@remi)
           Requires: libmysqlclient.so.18(libmysqlclient_16)(64bit)
           Removing: mysql-libs-5.5.60-1.el6.remi.x86_64 (@remi)
               libmysqlclient.so.18(libmysqlclient_16)(64bit)
           Obsoleted By: mysql-community-libs-5.6.40-2.el6.x86_64 (mysql56-community)
               Not found
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

答案1

您可能必须将某些软件包回滚到以前的版本才能安装您想要安装的软件包。我知道当我尝试将 CentOS 从 7.4 升级到 7.5 时也遇到了类似的问题。来自 EPEL 的软件包位于更新存储库中的软件包之前,因此升级无法运行。我必须将该包回滚到更新存储库中的版本。

yum 命令的示例可以在“如何检查 rpm 系统中可用的软件包版本?”用于检查哪些包可以回滚。

yum --showduplicates list <package>

当您找到所需的包时,您可以输入yum downgrade <package-name-version>

然后,降级后,您继续升级,尝试完成重点关注尝试安装的软件包,然后是系统的其余部分。

在你的情况下:

[thebtm@server ~]# yum --showduplicates list php-mysql
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * base: mirror.it.ubc.ca
 * epel: muug.ca
 * extras: mirror.it.ubc.ca
 * ius: mirrors.kernel.org
 * updates: mirror.it.ubc.ca
Available Packages
php-mysql.x86_64          5.4.16-45.el7            base 
[thebtm@server ~]# yum downgrade php-mysql --disablerepo=remi-safe

答案2

实际上是因为你安装了 remi rpm。首先你必须摆脱 remi repolist。

首先运行“yum repolist”,它将为您提供所有已安装的存储库列表。

然后删除 remi 的东西

“rpm -e --nodeps 雷米*”

然后,删除所有冲突的 rpm,如“php-mysql-5.4.45-14.el6.remi.x86_64”,“yum remove php-mysql”重新安装它们。“yum install php-mysql”

一切顺利,请使用“yum update mysql”重试

相关内容