Logrotate Cron Problem
Posted by Planet Malaysia on September 4, 2006
The cron daemon keeps email me about the cron problem.
This is the error message:
/etc/cron.daily/logrotate:
error: bad line 45 in state file /var/lib/logrotate.status
in /var/spool/mail/root
Edit /var/lib/logrotate.status and found there is missing ” in line 45
Sample of /var/lib/logrotate.status
"/var/log/messages" 2006-8-16
"/var/log/secure" 2006-8-16
"/var/log/maillog" 2006-8-16
"/var/log/spooler" 2006-8-16
"/var/log/boot.log" 2006-8-16
"/var/log/cron" 2006-8-16
The simple solution for this is :
1) Take a back up of the logrotate.status file.
mv /var/lib/logrotate.status /var/lib/logrotate.status.orig
OR
2) Run logrotate command manually to re-generate this file again
logrotate -fv /etc/logrotate.conf
OR
3) Delete the empty logrotate.status and run logrotate again:
/etc/cron.daily/logrotate /etc/logrotate.conf
This should solve the cron problem.
Possibly Related Posts:
- lppasswd: Unable to open passwd file: Permission denied
- Missing /var/log/lastlog
- Telnet service_limit error
- How to Add Date And Time To Your Bash History on SuSE Linux
- RPM Segmentation Fault
Comments
Leave a Reply