syslog log rotation

Alex Kiernan alexk at
Wed Apr 25 07:38:45 UTC 2001

James Ralston <qralston+ml.inn-workers at> writes:

> On Wed, 25 Apr 2001, Olaf Titz wrote:
> > As I see it the rotating program should not create the new log file
> > at all, since syslog will do that as soon as it is reloaded (and at
> > the same moment the old one gets closed).  [...]  Or are there
> > syslogds braindamaged enough that they can't handle this?
> Yes: most of them.  For example, no version of SunOS/Solaris syslogd
> (up to and including Solaris 8) will create log files.  In fact, the
> Linux syslogd is the first syslog implementation I've encountered that
> *will* create log files if they don't exist.  (I don't have access to
> a *BSD box at the moment, although I'd guess that most of their
> syslogds would be able to create log files as well.)

The FreeBSD 4.3 source doesn't look that way... certainly with a quick
test its not creating files on the fly.

> BTW, it occurred to me that an alternative to writing a hupsyslogd
> program would be to redesign the news.daily script to be invoked as
> root.  That way, it could su to news for most of its tasks, but run
> scanlogs as root.  Scanlogs would be modified to ensure that all files
> it creates are user news, group news.
> Writing a hupsyslogd program would probably take less effort,
> though...


Alex Kiernan, Principal Engineer, Development, Thus PLC

More information about the inn-workers mailing list