Re: [OT] fail2ban update (epel) breaks logrotate

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



In article <n009u2$85v$1@xxxxxxxxxxxxxxxxxxxxx>,
Tony Mountifield <tony@xxxxxxxxxxxxx> wrote:
> Apologies, this is slightly off-topic being to do with an EPEL package,
> although it's running on CentOS6, so I thought others here might have come
> across this issue.
> 
> I have five CentOS 6 systems running fail2ban from EPEL, and this
> package was updated in the last week from 0.9.2-1.el6 to 0.9.3-1.el6.
> 
> On all these systems, I received an error from logrotate this morning.
> 

> [root@system ~]# /usr/bin/fail2ban-client flushlogs
> logs: rolled over
> Traceback (most recent call last):
>   File "/usr/bin/fail2ban-client", line 470, in <module>
>     if client.start(sys.argv):
>   File "/usr/bin/fail2ban-client", line 440, in start
>     return self.__processCommand(args)
>   File "/usr/bin/fail2ban-client", line 281, in __processCommand
>     return self.__processCmd([cmd])
>   File "/usr/bin/fail2ban-client", line 185, in __processCmd
>     client.close()
>   File "/usr/lib/python2.6/site-packages/fail2ban/client/csocket.py", line 55, in close
>     self.__csock.sendall(CSPROTO.CLOSE + CSPROTO.END)
>   File "<string>", line 1, in sendall
> socket.error: [Errno 32] Broken pipe
> [root@system ~]#

OK, on further investigation, I found that the fail2ban service had not
been restarted by the update script.

So I restarted it, and got the same error as it was stopping, but it
started up ok. After restarting, the error no longer occurs:

[root@system ~]# ps -fC fail2ban-server
root      7528     1  0 Sep23 ?        00:10:06 /usr/bin/python -Es /usr/bin/fail2ban-server -s /var/run/fail2ban/fail2ban.sock -p /var/run/fail2ban/fail2ban.pid -x -b
[root@system ~]# service fail2ban restart
Stopping fail2ban: Traceback (most recent call last):
  File "/usr/bin/fail2ban-client", line 470, in <module>
    if client.start(sys.argv):
  File "/usr/bin/fail2ban-client", line 440, in start
    return self.__processCommand(args)
  File "/usr/bin/fail2ban-client", line 281, in __processCommand
    return self.__processCmd([cmd])
  File "/usr/bin/fail2ban-client", line 185, in __processCmd
    client.close()
  File "/usr/lib/python2.6/site-packages/fail2ban/client/csocket.py", line 55, in close
    self.__csock.sendall(CSPROTO.CLOSE + CSPROTO.END)
  File "<string>", line 1, in sendall
socket.error: [Errno 32] Broken pipe
                                                           [FAILED]
Starting fail2ban:                                         [  OK  ]
[root@system ~]# ps -fC fail2ban-server
root     11647     1  1 15:30 ?        00:00:00 /usr/bin/python -Es /usr/bin/fail2ban-server -s /var/run/fail2ban/fail2ban.sock -p /var/run/fail2ban/fail2ban.pid -x -b
[root@system ~]# /usr/bin/fail2ban-client flushlogs
logs: rolled over
[root@system ~]#

Hope this info is useful to others...

Cheers
Tony

-- 
Tony Mountifield
Work: tony@xxxxxxxxxxxxx - http://www.softins.co.uk
Play: tony@xxxxxxxxxxxxxxx - http://tony.mountifield.org
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
https://lists.centos.org/mailman/listinfo/centos



[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux