1

Topic: jail2ban whitelisting not operative

==== Required information ====
- iRedMail version (check /etc/iredmail-release):
- Linux/BSD distribution name and version:
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx):
- Manage mail accounts with iRedAdmin-Pro?
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
======== Required information ====
- iRedMail version (check /etc/iredmail-release):
- Linux/BSD distribution name and version:
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx):
- Manage mail accounts with iRedAdmin-Pro?
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
======== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.7
- Linux/BSD distribution name and version:  Ubuntu 16
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Web server (Apache or Nginx): apache
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

My system crash was solved with the realization that  fail2ban was at fault.  Disabling fail2ban prevents my system crash where the entrire system just stops.   Major success.  But I then lose the advantage and protection of fail2ban. 

However, the whitelisting on line <ignoreIP> in jail.local is not working.  It is not whitelisting my iRed <server address>.  Changing the bantime was critical.  Reduced from 3600 to 600.  But the system still stops a few times dialy for this 600 sec interval.

Why is whitelisting not working? I am using both internal and external IP addresses.  Then instead of the IP address I entered <mail.myserver.com> (myserver is just an example).  I even tried my local internet IP address.  Still not successful

So why is whitelisting not working?   
Where is a log or coding for banned IPs?
The log for jail2ban is empty.  There is no active logging

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: jail2ban whitelisting not operative

the fail2ban is now fully functional.  I made two changes.  Not sure which solved the problem.  I added my local IP address in CIDR format   xx.xx.xx.xx/32   So it only accepts the dedicate IP.  I added a second one from my office also in CIDR format.  So it was never clear whether it is the iRedMail server IP or the local hosting IP that was necessary to "white list" and prevent the downtimes.   And again decreasing the bantime was also super important.  From 3600 to 600.

3

Re: jail2ban whitelisting not operative

You should update Fail2ban to whitelist your client IP address, not iRedMail server itself.

4

Re: jail2ban whitelisting not operative

Thank you Zhang.   By Client IP I assume you mean our local hosting IP address, i.e., Comcast or similar.   I think CIDR notation seemed to make a difference.    xxx.xxx.xxx.xxx/32     It is now working with only rare downtime.   As we come to know more of the hidden fetures, it is richer and richer.