![在 RHEL6.2 上安装 perl-Time-HiRes 时出现 perl 依赖错误](https://linux22.com/image/629354/%E5%9C%A8%20RHEL6.2%20%E4%B8%8A%E5%AE%89%E8%A3%85%20perl-Time-HiRes%20%E6%97%B6%E5%87%BA%E7%8E%B0%20perl%20%E4%BE%9D%E8%B5%96%E9%94%99%E8%AF%AF.png)
尝试安装 perl-Time-HiRes 时出现以下信息:
host1:user1 > sudo yum install perl-Time-HiRes
Loaded plugins: product-id, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package perl-Time-HiRes.x86_64 4:1.9721-119.el6_1.1 will be installed
--> Processing Dependency: perl = 4:5.10.1-119.el6_1.1 for package: 4:perl-Time-HiRes-1.9721-119.el6_1.1.x86_64
--> Finished Dependency Resolution
Error: Package: 4:perl-Time-HiRes-1.9721-119.el6_1.1.x86_64 (rhel-6-6.2-server)
Requires: perl = 4:5.10.1-119.el6_1.1
Installed: 4:perl-5.10.1-129.el6.x86_64 (@anaconda-RedHatEnterpriseLinux-201301301459.x86_64/6.4)
perl = 4:5.10.1-129.el6
Available: 4:perl-5.10.1-119.el6_1.1.x86_64 (rhel-6-6.2-server)
perl = 4:5.10.1-119.el6_1.1
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
我不明白。它似乎在寻找 perl-5.10.1-129?但据我所知,最新的可用版本是 perl-5.10.1-119。
我已经启用了 EPEL 存储库,但这个包来自存储库rhel-6-6.2-server
。
我实际上正在尝试安装munin-node
,但是在同一个包上失败。
答案1
这确实是一条评论,但我的积分不够……
我在执行 yum 更新时也遇到过类似的问题。(并且是 yum update 而不是 yum upgrade)。
通常,通过执行“yum update”可以轻松解决这个问题,即“yum update perl”,如果成功,则执行“yum update perl-Time-HiRes”
答案2
正如 @MichaelHampton 所指出的,我实际上使用的是 6.4,但它被配置为使用 6.2 存储库(猜测是服务器为我构建时的一个错误)。使用 6.4 存储库工作正常。