yum安装包时提示libstdc++版本冲突

发布于 2022-09-03 15:16:53 字数 2747 浏览 11 评论 0

我本来想安装certbot,结果在运行完./certbot-auto certonly后会使用yum来初始化安装若干的包,不过运行一段时间后,就报错了:

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 libstdc++ which is missing some
            dependency that another package requires. Yum is trying to
            solve this by installing an older version of libstdc++ 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 libstdc++.otherarch ... this should give you an error
            message showing the root cause of the problem.
       
         2. You have multiple architectures of libstdc++ 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 libstdc++ 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: libstdc++-4.8.2-8.el6.x86_64 != libstdc++-4.4.7-17.el6.i686
Error: Protected multilib versions: libstdc++-devel-4.8.2-8.el6.x86_64 != libstdc++-devel-4.4.7-17.el6.i686
Error: Protected multilib versions: libgcc-4.8.2-8.el6.x86_64 != libgcc-4.4.7-17.el6.i686
Could not install OS dependencies. Aborting bootstrap!

然后我运行rpm -qa | grep libstdc后输出:

compat-libstdc++-33-3.2.3-69.el6.i686
libstdc++-devel-4.4.7-17.el6.i686
libstdc++-devel-4.4.7-17.el6.x86_64
libstdc++-4.4.7-17.el6.x86_64
libstdc++-4.4.7-17.el6.i686
compat-libstdc++-296-2.96-144.el6.i686
compat-libstdc++-33-3.2.3-69.el6.x86_6

我感觉这几个compat开头的包很可疑,于是乎把他们都删除了,但是回来接着运行certbot-auto还是报同样的错误。网上有人说运行下面命令可以解决冲突:

yum downgrade libgomp
yum downgrade libstdc++
yum downgrade libgcc
yum downgrade cpp

但是我运行完成后,依然没有效果。

certbot-auto是一个脚本文件,里面的代码比较长,这个脚本里面每个yum命令后面追加--setopt=protected_multilib=false我认为是可以的,但是我不想这么解决,还是想找到一个釜底抽薪的解决方案。
我的操作系统是centos 6.8

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文