Re: bind and syslog
On 17-Dec-99, 13:05 (CST), Marek Habersack <firstname.lastname@example.org> wrote:
> * Steve Greenland said:
> > IMO, this is a bug in syslog(3). IIRC, it only affects programs that
> No, it isn't. You can't expect syslogd to keep an open connection to
> /dev/log when it is being restarted...
No, but I can expect syslog(3) (the library function) to catch the
signal and re-open. Ok, it would have to maintain state, but doesn't
it anyway? It's not like openlog() returns a handle that's passed to
syslog. Why force every user to deal with this? Especially since there's
no real hint on the man page that it might be necessary. (Hmm, I guess
that's the one man page I shouldn't complain about...:-))
> Calling just syslog is what causes much mess to happen - too many programs
> use it and then your logs are full of messages mixed from many irrelevant
> sources... openlog/syslog/closelog is the appropriate sequence.
Oh, agree 100%. My point was that the openlog()/syslog() sequence
causes the SIGPIPE, while just using syslog() doesn't -- this actually
encourages people to just use syslog(), which is bad.
> The workaround is not to keep an open connection to the syslog. System
> log messages should be as infrequent as possible, so there's no real
> penalty in invoking openlog/syslog/closelog each time a message is
Well, cron, for one, calls it a lot (depending on syslog.conf, of
course). The overhead might still be negligible...
Steve Greenland <email@example.com>
(Please do not CC me on mail sent to this list; I subscribe to and read
every list I post to.)