如何用 yum 动态交换两个 rpm?

如何用 yum 动态交换两个 rpm?

我正在尝试根据以下说明在 CentOS7 机器上安装启用 MPTCP(多路径 TCP)的内核和工具安装文档。需要安装3个rpm包。我在安装iproute-mptcp_v0.94时遇到了一个问题。

[root@c7builder tmp]# yum install iproute-mptcp_v0.94
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.aliyun.com
 * epel: mirrors.yun-idc.com
 * extras: mirrors.aliyun.com
 * updates: mirrors.huaweicloud.com
Package iproute is obsoleted by iproute-tc, trying to install iproute-tc-mptcp_v0.94-5.fc24.x86_64 instead
Resolving Dependencies
--> Running transaction check
---> Package iproute-tc.x86_64 0:mptcp_v0.94-5.fc24 will be installed
--> Processing Dependency: iproute(x86-64) = mptcp_v0.94-5.fc24 for package: iproute-tc-mptcp_v0.94-5.fc24.x86_64
--> Finished Dependency Resolution
Error: Package: iproute-tc-mptcp_v0.94-5.fc24.x86_64 (bintray-cpaasch-rpm)
           Requires: iproute(x86-64) = mptcp_v0.94-5.fc24
           Installed: iproute-4.11.0-14.el7.x86_64 (@anaconda)
               iproute(x86-64) = 4.11.0-14.el7
           Available: iproute-mptcp_v0.91-4.fc24.x86_64 (bintray-cpaasch-rpm)
               iproute(x86-64) = mptcp_v0.91-4.fc24
           Available: iproute-mptcp_v0.92-4.fc24.x86_64 (bintray-cpaasch-rpm)
               iproute(x86-64) = mptcp_v0.92-4.fc24
           Available: iproute-mptcp_v0.93-4.fc24.x86_64 (bintray-cpaasch-rpm)
               iproute(x86-64) = mptcp_v0.93-4.fc24
           Available: iproute-mptcp_v0.94-5.fc24.x86_64 (bintray-cpaasch-rpm)
               iproute(x86-64) = mptcp_v0.94-5.fc24
           Available: iproute-4.11.0-14.el7_6.2.x86_64 (updates)
               iproute(x86-64) = 4.11.0-14.el7_6.2
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

看起来“iproute-mptcp_v0.94”需要先安装“iproute-tc-mptcp_v0.94”,但“iproute-tc-mptcp_v0.94”也需要前者!我对此感到困惑。有人愿意为我解释一下吗?

答案1

       Requires: iproute(x86-64) = mptcp_v0.94-5.fc24
       Installed: iproute-4.11.0-14.el7.x86_64

版本标签表明这是您尝试在 CentOS 7 上使用的 Fedora 24 包。这将不起作用。

找到一个等效的 el7 包。或者自己针对 el7 进行编译。

相关内容