我为 el7 安装了错误版本的 rpmforge。然后我运行了一个更新,在我的系统上安装了这个包
python-crypto-2.6.1-1.el7.rf.x86_64
请注意 el7,但我使用的是 rhel6。然后我意识到并删除了错误的存储库并为 el6 安装了正确的存储库。
$ rpm -qa | grep rpmfor
rpmforge-release-0.5.2-2.el6.rf.x86_64
但上述过程破坏了更新过程,我知道我可以使用 --skip-broken
选项解决这个问题。如何降级上述软件包。我尝试卸载并重新安装它,但出现此错误:
Error: Trying to remove "c4ebpl", which is protected
它显示了一些无法删除的 protected 包。
使用 sudo yum update
的更新过程给我这个错误:
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: libgmp.so.10()(64bit)
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: libc.so.6(GLIBC_2.14)(64bit)
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: python(abi) = 2.7
Installed: python-2.6.6-52.el6.x86_64 (@el66/$releasever)
python(abi) = 2.6
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: libpython2.7.so.1.0()(64bit)
You could try using --skip-broken to work around the problem
谁知道如何降级到原来的包?有没有办法恢复出厂设置?或者我需要重新安装 linux 吗?
我尝试过的一些事情:
我使用此命令删除了 python-crypto.x86_64
包
sudo rpm --nodeps -e python-crypto.x86_64
更新成功了。所以我想我现在应该安装 python-crypto.x86_64
包,因为我有正确的 el6 rpmforge 存储库。所以我运行了这个命令 sudo yum install python-crypto.x86_64
但我得到了同样的错误:
Resolving Dependencies
--> Running transaction check
---> Package python-crypto.x86_64 0:2.6.1-1.el7.rf will be installed
--> Processing Dependency: python(abi) = 2.7 for package: python-crypto-2.6.1-1.el7.rf.x86_64
--> Processing Dependency: libc.so.6(GLIBC_2.14)(64bit) for package: python-crypto-2.6.1-1.el7.rf.x86_64
--> Processing Dependency: libpython2.7.so.1.0()(64bit) for package: python-crypto-2.6.1-1.el7.rf.x86_64
--> Processing Dependency: libgmp.so.10()(64bit) for package: python-crypto-2.6.1-1.el7.rf.x86_64
--> Finished Dependency Resolution
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: libgmp.so.10()(64bit)
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: libc.so.6(GLIBC_2.14)(64bit)
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: python(abi) = 2.7
Installed: python-2.6.6-52.el6.x86_64 (@el66/$releasever)
python(abi) = 2.6
Error: Package: python-crypto-2.6.1-1.el7.rf.x86_64 (rpmforge)
Requires: libpython2.7.so.1.0()(64bit)
You could try using --skip-broken to work around the problem
我不知道它为什么要查找 el7 包?我的机器中有这些库。
$ rpm -qa | grep rpmfor
rpmforge-release-0.5.3-1.el7.rf.x86_64
最佳答案
来自 @Michael Hapton 的解决方案在 this link
这是解决方案。我不认为这是功劳。
首先您需要安装正确的 rpmforge-release 包。下载它并使用 rpm -U --oldpackage 将其安装到错误的包上。
其次,您需要清理它拥有的缓存 yum 元数据。使用 yum clean all 清除所有内容。
第三,使用 yum distro-sync 降级任何为错误的发行版安装的软件包。 (请注意,这还将升级任何过时的软件包。)
关于linux - RHEL6 安装了错误版本的 rpmforge,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31622991/