sysklogd doesn't use logrotate

Bug #255226 reported by Marty
16
This bug affects 1 person
Affects Status Importance Assigned to Milestone
sysklogd (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: sysklogd

sysklogd should really use logrotate.

syslogd-listfiles is an inflexible way to select specific logs and apply different options to them. It doesn't support monthly rotation at all.

There is no configuration file for syslogd-listfiles which means you have to change /etc/cron.*/sysklogd or even the perl script itself. You then have to deal with merging changes when sysklogd is upgraded.

There have been proposals in Debian to either fix syslogd-listfiles (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=104278) or switch to logrotate (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=44523) but neither have gone anywhere in some time.

Revision history for this message
Tom Metro (tmetro+ubuntu) wrote :

For a long time I've used a workaround for this problem that moves all sysklogd generated files to /var/log/syslog/ and then uses this logrotate config file:

/var/log/syslog/*.log {
        olddir /var/log/syslog/old
        sharedscripts
        postrotate
                /etc/init.d/sysklogd reload-or-restart > /dev/null
        endscript
}

Solves the problem cleanly, and I wish Debian would adopt this, but they're understandably concerned about moving the location of common log files.

Another approach would be to patch sysklogd to have a command line option where it will output the definitive list of log files parsed from its config file (supplanting the external shell script hack). Unfortunately you can't simply do `sysklogd --listfiles` in logrotate, due to its inflexibility. (Boggles the mind why a log rotation program was written in C instead of Perl. See also http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=326421 and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=353663 )

Revision history for this message
Charlie Schluting ☃ (cschluti) wrote :

+1 the original bug report. We need one definitive place to configure rotation and permissions..

Changed in sysklogd (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.