PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : crond /usr/sbin/logrotate fehlt



der_neue_3er
07.11.04, 13:15
Hallo,

nach dem Motto 'täglich grüßt das Murmeltier' bekomme ich jeden Tag um 6.25 Uhr eine Mail meines crondaemon mit folgendem Inhalt.



subject: Cron <root@localhost> test -e /usr/sbin/anacron || run-parts --report /etc/cron.daily

/etc/cron.daily/logrotate:
/etc/cron.daily/logrotate: /usr/sbin/logrotate: No such file or directory
run-parts: /etc/cron.daily/logrotate exited with return code 127

Jetzt habe ich spasseshalber mal eine 0-Byte-Datei namens logrotate in /usr/sbin/ angelegt und die Meldung blieb natürlich aus.
Ich stellte aber später fest, dass das postfix mail.log gelöscht war (scheinbar wurde es dann wohl heute morgen um 6.25Uhr gelöscht) und sich dort erst wieder Inhalt hineinschrieb als ich per postfix eine Email versandt.

Frage:
- hängt dass damit wirklich zusammen?
- was muss dann in der logrotate stehen damit die Meldung ausbleibt, als 0-Byte-Datei kann das ja sicher nicht bleiben?

Über google habe ich mit der Fehlermeldung nicht wirklich viel gefunden.

Grüße
Patrick

carnil
07.11.04, 13:28
Hi

Vorschlag: logrotate installieren?
Was ist logrotate:


Description: Log rotation utility
The logrotate utility is designed to simplify the administration of
log files on a system which generates a lot of log files. Logrotate
allows for the automatic rotation compression, removal and mailing of
log files. Logrotate can be set to handle a log file daily, weekly,
monthly or when the log file gets to a certain size. Normally, logrotate
runs as a daily cron job.


MfG carnil

der_neue_3er
07.11.04, 14:03
Hi carnil,
klingt logisch :o habs jetzt mal installiert und siehe da, nun gibt es eine wirkliche /usr/sbin/logrotate.

Wer hat aber sonst die ganzen logfiles rotieren lassen?
Denn die sind alle schön Zeitschematisch gepackt.