I have a couple of cron jobs in cron.daily which are supposed to execute daily. I know these tasks get executed as I can see the end result. For example: I'm doing a back-up of MySQL DB and I can see the back-up file. However, I cannot find the log for this.

  • I checked /var/log/syslog with a grep CRON /var/log/syslog command all I can find is php5 session clean cronjob(I don't really know what that is)

Where can I find the log for cron.daily?

2

1 Answer

All cron jobs (in a Debian based system like Ubuntu) are logged in /var/log/syslog. You are looking for "CRON" in all caps, so first step is to do a case insensitive search:

grep -i cron /var/log/syslog 

Next, syslog may only show the last 24 hours or less meaning you may not see the daily entry in there. Try searching old syslog files as well:

zgrep -i cron /var/log/syslog* 

You should be able to narrow down the results even further using:

zgrep -i cron.daily /var/log/syslog* 
5

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy