Quote:
Originally Posted by rknichols
What you can do is look in /var/log/cron (you may need to be root to do that) and see what happened when (or if) the cron daemon tried to run your job, though in most cases there would have been mail sent to the owner of the crontab if the job failed.
|
This is how I have added the job to crontab
I use nano editor
sudo -u www-data crontab -e
*/15 * * * * php /var/www/owncloud/occ files:scan --all
Ctrl+O to save then I get back to terminal, and I get installing, that's all I get
I don't have a cron.log In Ubuntu
I have uncommented this line
/etc/rsyslog.d/50-default.conf
Find the line that starts with:
#cron.*
uncomment that line, save the file, and restart rsyslog:
sudo service rsyslog restart
I got the cron.log now
I can attach the file to the system, i get invalid file
Any way this is the cron log
Apr 5 12:06:03 ubuntu crontab[5410]: (www-data) BEGIN EDIT (www-data)
Apr 5 12:06:15 ubuntu crontab[5410]: (www-data) END EDIT (www-data)
Apr 5 12:06:18 ubuntu crontab[5424]: (www-data) BEGIN EDIT (www-data)
Apr 5 12:08:26 ubuntu crontab[5540]: (www-data) BEGIN EDIT (www-data)
Apr 5 12:09:01 ubuntu CRON[5608]: (root) CMD ( [ -x /usr/lib/php5/maxlifetime ] && [ -x /usr/lib/php5/sessionclean ] && [ -d /var/lib/php5 ] && /usr/lib/php5/sessionclean /var/lib/php5 $(/usr/lib/php5/maxlifetime))
Apr 5 12:15:01 ubuntu CRON[5745]: (www-data) CMD (php /var/www/owncloud/occ files:scan --all)
Apr 5 12:17:01 ubuntu CRON[5772]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)