Ubuntu – cron logs stored on Ubuntu 14.04

14.04cron

I am trying to troubleshoot why my cron task isn't working sometimes. Where does cron store log files by default? Is it /var/log/syslog ?

I have looked at that file and it is empty. Do I need to set something up?

Best Answer

As default, cron's logs saved in /var/log/syslog. It depends on rsyslogd configuration. You can change it:
Go to rsyslog config

cd /etc/rsyslog.d/
sudo nano 50-default.conf

Uncoment line:

#cron.*                         /var/log/cron.log

Save file and restart rsyslog

sudo service rsyslog restart 

Restart your cron daemon for get it's messages from new file

sudo service cron restart