RE: mulitlog not getting terminated when Red Hat reboots?
"Daryl Tester" <[email protected]> Wed, 24 Jan 2007 10:31:31 +1030
| Newsgroups | gmane.comp.djb.syslog |
|---|---|
| Message-ID | <[email protected]> |
Brian Reichert wrote: > Daryl Tester wrote: >> Those of us that don't kill svscan on shutdown, yes. :-) > How do you avoid that, then, without just pulling the plug out of > the wall? :) Oh yeah, there is that. :-/ My shutdown script (from memory, I'm not at the machine) "svc -d"'s the services, waits for them to show as "down" (with timeout in case of hang), waits a couple of seconds, then shuts down the services' loggers. The rationale behind the wait between service and logger shutdown is to allow time for the pipe to empty (I sometimes have fairly elaborate multilog processor scripts). The halt/reboot/ unplanned power outage then takes care of svscan. :-) It would be nice if the service exit would close the pipe to the logging process (shutdown on the logger could then be a "svc -o" and wait for multilog termination due to EOF on pipe), but svscan holds the write end of the pipe open, so the logger will only see EOF if you kill svscan. -- Regards, Daryl Tester, IOCANE Pty. Ltd.