Re: daemons logging to a file

[email protected] (Paul Jarc)
Newsgroups gmane.comp.djb.syslog
Organization What did you have in mind? A short, blunt, human pyramid?
Message-ID <[email protected]>
"Rob Mayoff" <[email protected]> wrote:
> +---------- On Oct 31, Paul Jarc said:
> | #!/bin/sh
> | exec \
> | setuidgid whoever \
> | multilog t ./main < ../fifo
>
> Under this arrangement, if he restarts the log service, and $program
> writes something to the pipe while multilog is down, $program will get
> SIGPIPE.

Ah, true.  But under the original arrangement, cat is unsupervised; it
could be killed, and we'd have the same problem, with even greater
likelihood, since cat wouldn't be automatically restarted.  Making one
cat/multilog service and another daemon-with-no-logger service (with
cat and the daemon connected by the fifo) would take care of
automatically restarting cat, but we'd still have the same problem
with a small window.  Best to fix the daemon, of course, preferably
with the maintainer's cooperation.


paul
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.