„If there’s more than one possible outcome of a job or task, and one
of those outcomes will result in disaster or an undesirable consequence,
then somebody will do it that way.“ -- Edward Aloysius Murphy Jr.
# see "man logrotate" for details
# rotate log files weekly
weekly
# keep 4 weeks worth of backlogs
rotate 4
# create new (empty) log files after rotating old ones
create
# uncomment this if you want your log files compressed
compress
# packages drop log rotation information into this directory
include /etc/logrotate.d
# no packages own wtmp, or btmp -- we'll rotate them here
/var/log/wtmp {
missingok
monthly
create 0664 root utmp
rotate 1
}
/var/log/btmp {
missingok
monthly
create 0664 root utmp
rotate 1
}
# system-specific logs may be configured here
die logs sollten eigentlich wöchentlich rotieren - habe ich etwas übersehen?
„If there’s more than one possible outcome of a job or task, and one
of those outcomes will result in disaster or an undesirable consequence,
then somebody will do it that way.“ -- Edward Aloysius Murphy Jr.
dieser cronjob existiert allerdings schon seit 3 monaten - das hat mich etwas gewundert.
außerdem war ich der meinung, dass ein manuelles starten von logrotate dies zumindest
bei der erstmaligen ausführung ignoriert...
man 8 logrotate wrote: -d Turns on debug mode and implies -v. In debug mode, no changes will be made to the logs or to the logrotate state file.
-f, --force
Tells logrotate to force the rotation, even if it doesn’t think this is necessary. Sometimes this is useful after adding new entries to a logrotate config file, or if old log files have been removed by hand, as the new files will be created, and logging will continue correctly.
Beide Parameter (getrennt voneinander) schon ausprobiert?
hat geholfen. eine letzte frage: woran erkenne ich, warum logrotate
noch keine notwendigkeit zum rotieren gesehen hatte? an "weekly"
kann es eigentlich nicht liegen - es wurde ja schon einige monate
nicht rotiert...