我们正面临fail2ban的问题。
例如,我们的设置:
jail.conf:
[nginx-404]
enabled = true
port = http,https
filter = nginx-404
logpath = /var/log/nginx/*access.log
maxretry = 5
findtime = 300
action = mail
比行动:
[Definition]
actionstart =
actionstop =
actioncheck =
actionban = printf %%b "Hi,n
The IP <ip> has just been banned by Fail2Ban after
<failures> attempts against <name>.n
Regards,n
Fail2Ban"|mail -s "[Fail2Ban] <name>: banned <ip> from `uname -n`" <dest>
actionunban =
重新启动服务或重新启动系统后。它立即发出了以前的所有禁令。
有什么解决方案可以在重新启动后停止发送数百个通知吗?谢谢你的建议。
有什么解决方案可以在重启后停止发送数百个通知吗?
是。只需在操作中指定norestored = true
即可。请参阅PR#1669了解更多信息。