Fehler:
/etc/cron.daily/logrotate:
gzip: stdin: file size changed while zipping
Fix:
In English, you can read this bug report.
To summarise:
- First you have to add the
--verboseoption in the script/etc/cron.daily/logrotateto have more information the next time it runs to identify which rotation log cause the problem.#!/bin/shtest -x /usr/sbin/logrotate || exit 0
/usr/sbin/logrotate –verbose /etc/logrotate.conf` - Next you have to add the
delaycompressoption in logrotate configuration.
Anmerkung/Beispiel:
Nachdem –verbose hinzugefügt wurde konnte der Verursache Munin identifiziert werden:
renaming /var/log/munin/munin-update.log to /var/log/munin/munin-update.log.1
creating new /var/log/munin/munin-update.log mode = 0640 uid = 110 gid = 4
compressing log with: /bin/gzip
gzip: stdin: file size changed while zipping
In /etc/logrotate.d/munin setzen wir jetzt nun die delaycompress option:
/var/log/munin/munin-update.log {
daily
missingok
rotate 7
compress
notifempty
create 640 munin adm
delaycompress
}
