* Thomas Lamy <[EMAIL PROTECTED]> [20030823 08:41]: wrote:It's just that from time to time, a server dies or needs to be hot-rebooted. This is the case for me on at least 4 servers last week, because of a 2 hour power loss (the ups shortened that by 10 minutes).Tomasz Kojm wrote:"Travis Robertson" <[EMAIL PROTECTED]> wrote:I have tried running clamd in local socket mode. The first time it
runs everything is ok, it creates the /var/run/clamd/clamd.socket. Whenever I reboot the server and it trys to build the socket, I get
the error "ERROR:
You should stop clamd cleanly - eg. by sending the SIGTERM signal.
What about the following pseudo-code at startup of clamd (instead of failing):
if (file exists(UNIX_SOCKET)) { if (connect(UNIX_SOCKET) != ERROR) { die ("Socket already exists"); } warn ("Socket already exists but is not connected - unclean shutdown?"); unlink (UNIX_SOCKET); }
I advocate this proposal. It will make life easier for us. Yesterday I had to commute back to the office because clamd died for some reason I still cannot determine, even though it's monitored by daemontools.
I just think it's not the /etc/rc.x's job to clean up "temporary" files. I'll come up with a patch 'till monday...
Thomas
------------------------------------------------------- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 _______________________________________________ Clamav-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/clamav-users