CentOS Multilib 版本冲突

CentOS Multilib 版本冲突

我正在尝试在我的 CentOS 6.6 上安装 HHVM,但是这个多库问题不允许我这样做。

运行后yum upgrade,我得到了这个结果。

root@invictus [~]# yum upgrade
Loaded plugins: fastestmirror
Setting up Upgrade Process
Loading mirror speeds from cached hostfile
 * aso: repo-uscentral.asonoc.com
 * base: centos.mirror.lstn.net
 * epel: fedora-epel.mirror.lstn.net
 * extras: repos.dfw.quadranet.com
 * rpmforge: mirror.nexcess.net
 * updates: repos.dfw.quadranet.com
Resolving Dependencies
--> Running transaction check
---> Package cpp.x86_64 0:4.4.7-11.el6 will be updated
---> Package cpp.x86_64 0:4.8.2-8.el6 will be an update
--> Processing Dependency: libmpc.so.2()(64bit) for package: cpp-4.8.2-8.el6.x86_64
---> Package curl.x86_64 0:7.19.7-40.el6_6.3 will be updated
---> Package curl.x86_64 0:7.29.0-4.el6 will be an update
---> Package gcc.x86_64 0:4.4.7-11.el6 will be updated
---> Package gcc.x86_64 0:4.8.2-8.el6 will be an update
---> Package gcc-c++.x86_64 0:4.4.7-11.el6 will be updated
---> Package gcc-c++.x86_64 0:4.8.2-8.el6 will be an update
---> Package gmp.x86_64 0:4.3.1-7.el6_2.2 will be updated
---> Package gmp.x86_64 1:4.3.2-4.el6 will be an update
---> Package libcurl.x86_64 0:7.19.7-40.el6_6.3 will be updated
---> Package libcurl.x86_64 0:7.29.0-4.el6 will be an update
---> Package libevent.x86_64 0:1.4.13-4.el6 will be updated
---> Package libevent.x86_64 0:1.4.14b-2.hphp.el6 will be an update
---> Package libgcc.x86_64 0:4.4.7-11.el6 will be updated
---> Package libgcc.x86_64 0:4.8.2-8.el6 will be an update
---> Package libgomp.x86_64 0:4.4.7-11.el6 will be updated
---> Package libgomp.x86_64 0:4.8.2-8.el6 will be an update
---> Package libstdc++.x86_64 0:4.4.7-11.el6 will be updated
---> Package libstdc++.x86_64 0:4.8.2-8.el6 will be an update
---> Package libstdc++-devel.x86_64 0:4.4.7-11.el6 will be updated
---> Package libstdc++-devel.x86_64 0:4.8.2-8.el6 will be an update
---> Package libtool.x86_64 0:2.2.6-15.5.el6 will be updated
---> Package libtool.x86_64 0:2.4.2-21.el6 will be an update
---> Package libtool-ltdl.x86_64 0:2.2.6-15.5.el6 will be updated
---> Package libtool-ltdl.x86_64 0:2.4.2-21.el6 will be an update
---> Package libtool-ltdl-devel.x86_64 0:2.2.6-15.5.el6 will be updated
---> Package libtool-ltdl-devel.x86_64 0:2.4.2-21.el6 will be an update
---> Package mpfr.x86_64 0:2.4.1-6.el6 will be updated
---> Package mpfr.x86_64 0:2.4.2-1.el6 will be an update
--> Running transaction check
---> Package libmpc.x86_64 0:0.8.3-0.3.svn855.el6 will be installed
--> Finished Dependency Resolution
Error:  Multilib version problems found. This often means that the root
       cause is something else and multilib version checking is just
       pointing out that there is a problem. Eg.:

         1. You have an upgrade for libgcc which is missing some
            dependency that another package requires. Yum is trying to
            solve this by installing an older version of libgcc of the
            different architecture. If you exclude the bad architecture
            yum will tell you what the root cause is (which package
            requires what). You can try redoing the upgrade with
            --exclude libgcc.otherarch ... this should give you an error
            message showing the root cause of the problem.

         2. You have multiple architectures of libgcc installed, but
            yum can only see an upgrade for one of those arcitectures.
            If you don't want/need both architectures anymore then you
            can remove the one with the missing update and everything
            will work.

         3. You have duplicate versions of libgcc installed already.
            You can use "yum check" to get yum show these errors.

       ...you can also use --setopt=protected_multilib=false to remove
       this checking, however this is almost never the correct thing to
       do as something else is very likely to go wrong (often causing
       much more problems).

       Protected multilib versions: libgcc-4.8.2-8.el6.x86_64 != libgcc-4.4.7-11.el6.i686
root@invictus [~]# 

跑步时yum check

root@invictus [~]# yum check
Loaded plugins: fastestmirror
python-libs-2.6.6-52.el6.x86_64 has missing requires of libffi.so.5()(64bit)
Error: check all
root@invictus [~]# 

答案1

问题是RHEL6/CentOS6 中没有libgcc.x86_64 0:4.8.2-8.el6软件包。EL6 的当前版本是 4.4.7-11,这是您当前安装的版本。

摆在你面前的任务是弄清楚为什么 yum 首先会找到这样的包。

首先,彻底清理 yum 缓存。可能有人无意中创建了这样的包,后来被拉了出来,但你的系统仍然有指向它的元数据。

yum clean all

第二,弄清楚 yum 在哪里这样的包来自哪里。运行:

yum list all libgcc

在干净的 CentOS 6.6 系统上您应该得到以下输出:

Installed Packages
libgcc.x86_64                         4.4.7-11.el6                         @base
Available Packages
libgcc.i686                           4.4.7-11.el6                         base 

如果您得到其他东西,则存储库将被识别,然后您可以禁用该存储库,联系其维护者,怀疑恶意活动等。

如果您获得相同的输出,那么您应该能够继续系统更新。

答案2

我也有类似的问题。当我尝试更新 centos7 时,我得到以下结果:

Multilib version problems found. This often means that the root
cause is something else and multilib version checking is just
pointing out that there is a problem. Eg.:

  1. You have an upgrade for device-mapper-libs which is missing some
     dependency that another package requires. Yum is trying to
     solve this by installing an older version of device-mapper-libs of the
     different architecture. If you exclude the bad architecture
     yum will tell you what the root cause is (which package
     requires what). You can try redoing the upgrade with
     --exclude device-mapper-libs.otherarch ... this should give you an error
     message showing the root cause of the problem.

  2. You have multiple architectures of device-mapper-libs installed, but
     yum can only see an upgrade for one of those architectures.
     If you don't want/need both architectures anymore then you
     can remove the one with the missing update and everything
     will work.

  3. You have duplicate versions of device-mapper-libs installed already.
     You can use "yum check" to get yum show these errors.

...you can also use --setopt=protected_multilib=false to remove
this checking, however this is almost never the correct thing to
do as something else is very likely to go wrong (often causing
much more problems).

Chronione wersje multilib: 7:device-mapper-libs-1.02.135-1.el7_3.2.x86_64 != 7:device-mapper-libs-1.02.135-1.el7_3.1.i686

就我而言,我遇到了问题device-mapper-libs。第一步,检查重复的包:

yum list --showduplicates device-mapper-libs-1.02.135-1.el7_3.1

Wczytane wtyczki: fastestmirror, langpacks Loading mirror speeds from
cached hostfile  * base: centos1.hti.pl  * epel: ftp.icm.edu.pl  *
extras: centos1.hti.pl  * nux-dextop: li.nux.ro  * updates:
ftp.icm.edu.pl  * webtatic: uk.repo.webtatic.com Zainstalowane pakiety
device-mapper-libs.i686                                               
7:1.02.135-1.el7_3.1                                                  
@updates device-mapper-libs.x86_64                                    
7:1.02.135-1.el7_3.1                                                  
@updates Dostępne pakiety device-mapper-libs.i686                     
7:1.02.135-1.el7_3.1                                                  
updates  device-mapper-libs.x86_64

接下来删除无效的包:

yum erase device-mapper-libs.i686

现在执行更新/升级。成功了。

答案3

我在更新 CentOS 7 系统时遇到了类似的问题。主要问题是更新过程引入了一些与本地计算机上安装的版本相冲突的依赖项。为了能够更新计算机,需要删除冲突的旧版本软件包,即

rpm -e --justdb --nodeps libgcc-4.4.7-11.el6.i686

有时 32 位和 64 位软件包之间也可能存在问题,解决方法如下这里

相关内容