sysklogd doesn't use logrotate
Bug #255226 reported by
Marty
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.
There have been proposals in Debian to either fix syslogd-listfiles (http://
To post a comment you must log in.
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 {
sharedscripts
/etc/ init.d/ sysklogd reload-or-restart > /dev/null
olddir /var/log/syslog/old
postrotate
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 )