我注意到我的auth.log有可疑的行为。 出于某种原因,每次旋转时都会旋转多次。
2014-06-15 06:25:06,102 fail2ban.filter : INFO Log rotation detected for /var/log/auth.log 2014-06-15 06:25:06,102 fail2ban.filter : INFO Log rotation detected for /var/log/auth.log 2014-06-15 06:25:20,117 fail2ban.filter : INFO Log rotation detected for /var/log/auth.log 2014-06-15 06:25:20,117 fail2ban.filter : INFO Log rotation detected for /var/log/auth.log
/etc/logrotate.d/ syslog-ng
/var/log/auth.log { rotate 4 weekly missingok notifempty compress delaycompress sharedscripts postrotate invoke-rc.d syslog-ng reload > /dev/null endscript }
我检查了旧的日志,发现这在几个月前就开始了。
那里出了什么问题?
这是因为在fail2ban中有多个filter,监视不同的failregex组合的同一个日志…例如你的apache,badbots和wordpressfilter…
find你的监狱文件,并运行以下命令:grep“/ var / log / auth”jail.local
或类似的东西,它应该显示你三个实例。