Bug 844911 - Fail2ban takes a very long amount of time to stop
Fail2ban takes a very long amount of time to stop
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: fail2ban (Show other bugs)
17
x86_64 Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Axel Thimm
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-01 04:57 EDT by Marco Guazzone
Modified: 2013-07-31 14:34 EDT (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-07-31 14:34:48 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Marco Guazzone 2012-08-01 04:57:56 EDT
Description of problem:
Fail2ban takes a very long amount of time to stop.

Version-Release number of selected component (if applicable):
0.8.4-28

How reproducible:
Install fail2ban and enable it at boot time through systemctl. Then reboot. At subsequent reboot/shutdown of the system, you should experience a very long amount of time before this action completes.

Steps to Reproduce:
1.sudo yum install fail2ban
2.sudo systemctl enable fail2ban.service; sudo systemctl start fail2ban.service
3.sudo reboot
  
Actual results:
System reboot/shutdown takes a very long amount of time to complete.
This delay can also be experienced if you stop fail2ban with systemctl.

Expected results:
As in Fedora 16, I expect fail2ban takes a very short time to stop.

Additional info:
I use fail2ban to block SSH attacks.
To do so, I've added the following jail.local file in /etc/fail2ban
--- [jail.local] ---
[DEFAULT]
bantime  = 43200
[ssh-iptables]
enabled  = true
filter   = sshd
action   = iptables[name=SSH, port=ssh, protocol=tcp]
           sendmail-whois[name=SSH, dest=root, sender=fail2ban@localhost]
logpath  = /var/log/secure
maxretry = 3
--- [/jail.local] ---
Comment 1 Marco Guazzone 2012-08-25 08:10:09 EDT
I think I've found a workaround/solution for this problem.
Firstly, I've installed a more recent version of fail2ban (i.e., ver. 0.8.7.1), along with patches (that I slightly modified) coming from the RPM packaged with Fedora 17 (if you (or the package maintainer) are interested, I can send you the files).

But maybe this step is useless, since alone it did not solve my problem...

Then, I add my host name in /etc/hosts, which only contained these entries:

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

After this, I'm able to poweroff/restart in a very short time :)

Don't know which between fail2ban and F17 (and maybe, sendmail?) is wrong. I mean:
* Should F17 has filled my /etc/hosts during installation time when one specifies the hostname?

* Should fail2ban or sendmail use localhost instead of the host name?

Cheers.
Comment 2 Olivier 2012-10-01 04:17:44 EDT
same problem here.

Adding host name to /etc/hosts fixed the problem
Comment 3 Cole Robinson 2012-10-07 11:28:05 EDT
I was hitting the same problem. I'm pretty sure this is sendmail's fault. Does 'sudo service sendmail restart' take a long time as well?

Do a google search for 'my unqualified hostname unknown' and you'll see this is a long standing sendmail thing.
Comment 4 Fedora End Of Life 2013-07-03 15:43:58 EDT
This message is a reminder that Fedora 17 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 17. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '17'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 17's end of life.

Bug Reporter:  Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 17 is end of life. If you 
would still like  to see this bug fixed and are able to reproduce it 
against a later version  of Fedora, you are encouraged  change the 
'version' to a later Fedora version prior to Fedora 17's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 5 Matt Baker 2013-07-18 11:23:56 EDT
This still happens on Fedora 19.   Marco's fix of adding my host name to /etc/hosts fixed the problem.  This may only effect people that change their host name.

Could this bug please be changed to fedora version 19 so that it is not automatically closed?  Thanks
Comment 6 Fedora End Of Life 2013-07-31 14:34:53 EDT
Fedora 17 changed to end-of-life (EOL) status on 2013-07-30. Fedora 17 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.