I have a Ubuntu system that has anacron installed. However I'm pretty sure it's not running. It's not running the commands in /etc/cron.daily to rotate the syslog files (I'm using sysklog, which has its own rotating log method, not using logrotate). The last time the logs were rotated were in October 2009. /var/spool/anacron/cron.daily
exists and the contents are 20091015
. AFAIR we had a power outage then, and everything rebooted.
How can I debug anacron? How can I see why it's not running? My first instinct is to look for /var/log/anacron
, but that's not there. How can I fix it to make it run again?
Best Answer
Look at the following:
The last entry on one system for me is November 4, 2008.
The entries range from December 28 through January 4 for me.
You should see entries similar to this for daily, weekly and monthly:
And this should show a bunch of files:
In
/etc/cron.daily
I have both logrotate and sysklogd.And if you do:
you should see that the
cron
daemon is running.If you do:
you should see a few lines that end in
|| exit 0
- check to make sure that the files exist and, for the ones withtest -x
that they are executable. Some of them don't for me since I'm using logrotate.Check to see if syslogd is running:
See if savelog exists and is executable:
That's all I can think of at the moment.