6

Fail2ban continues to block an ip even after I have whitelisted that ip.

I have in /etc/fail2ban/jail.conf a line like the following.

ignoreip = 53.45.114.103

However fail2ban continues to block this ip.

I see in the logs: 2016-01-07 13:34:38,180 fail2ban.actions [44813]: NOTICE [ssh] Ban 53.45.114.103 2016-01-07 13:34:38,496 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,515 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,529 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,534 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,545 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,546 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,547 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:38,563 fail2ban.filter [44813]: INFO [ssh] Found 53.45.114.103 2016-01-07 13:34:41,026 fail2ban.actions [44813]: NOTICE [ssh] 53.45.114.103 already banned

2
  • Have you restarted fail2ban after the change? and exactly where have you added the line? It should be under [DEFAULT] and also put it in the jail.local file.
    – Diamond
    Jan 7 '16 at 14:16
  • My issue was that I was only modifying the jail.conf file and the jail.local contained an entry for ignoreip. Create an answer and I'll select it.
    – bearrito
    Jan 10 '16 at 23:25
6

You need to edit the jail.local file and add the appropriate entry under the [DEFAULT] block and it should work.

0

What you might also need to check on, is if the config option you are using also doesn't have an ignoreip option set. For example, I had postfix enabled, and it had ignoreip as well. My IP was being blocked, even though it was in the default section.

So if you have ignoreip, under say postfix as well, it will override what is in the default section.

I just had this problem, so sharing it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.