无法在Centos 7.1上安装fail2ban

无法在Centos 7.1上安装fail2ban

我正在尝试在我的centos 7.1服务器上安装fail2ban

我做了:

 yum install epel-release
    yum install fail2ban

但我收到一些错误消息:

 yum install epel-release
    Package epel-release-7-5.noarch already installed and latest version
    Nothing to do

-----

[root@elliot ~]# yum install fail2ban
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * atomic: mirror1.34sp.com
 * base: centos.mirror.transip.nl
 * epel: ftp.nluug.nl
 * extras: centos.mirror.transip.nl
 * updates: centos.mirror.transip.nl
Resolving Dependencies
--> Running transaction check
---> Package fail2ban.noarch 0:0.9.2-1.el6 will be installed
--> Processing Dependency: python(abi) = 2.6 for package: fail2ban-0.9.2-1.el6.noarch
--> Processing Dependency: python-inotify for package: fail2ban-0.9.2-1.el6.noarch
--> Processing Dependency: gamin-python for package: fail2ban-0.9.2-1.el6.noarch
--> Running transaction check
---> Package fail2ban.noarch 0:0.9.2-1.el6 will be installed
--> Processing Dependency: python(abi) = 2.6 for package: fail2ban-0.9.2-1.el6.noarch
---> Package gamin-python.x86_64 0:0.1.10-16.el7 will be installed
--> Processing Dependency: gamin = 0.1.10-16.el7 for package: gamin-python-0.1.10-16.el7.x86_64
--> Processing Dependency: libgamin-1.so.0()(64bit) for package: gamin-python-0.1.10-16.el7.x86_64
---> Package python-inotify.noarch 0:0.9.4-4.el7 will be installed
--> Running transaction check
---> Package fail2ban.noarch 0:0.9.2-1.el6 will be installed
--> Processing Dependency: python(abi) = 2.6 for package: fail2ban-0.9.2-1.el6.noarch
---> Package gamin.x86_64 0:0.1.10-16.el7 will be installed
--> Finished Dependency Resolution
Error: Package: fail2ban-0.9.2-1.el6.noarch (epel)
           Requires: python(abi) = 2.6
           Installed: python-2.7.5-18.el7_1.1.x86_64 (@updates)
               python(abi) = 2.7
               python(abi) = 2.7
           Available: python-2.7.5-16.el7.x86_64 (base)
               python(abi) = 2.7
               python(abi) = 2.7
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest
[root@elliot ~]# 

有人可以帮我解决这个问题吗?我也尝试在新服务器上安装它,并且在该服务器上没有问题

PS如果你愿意的话可以登录我的电脑

答案1

看起来您可能epel-release安装了两个软件包 - 一个用于 EPEL 6,一个用于 EPEL 7。您的第一个yum命令显示epel-release-7-5已安装,第二个yum命令是拉入fail2ban-0.9.2-1.el6来自 EPEL 6(而不是 7)。如果是这种情况,您应该会看到两个结果rpm -q epel-release。如果您随后yum remove将 EPEL 6 发布包并发出 a yum clean all,那么您应该能够yum install fail2ban成功。

相关内容