Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Mac OS X cron log / tracking

What is the best way to determine if a cron job has run? Is there a log? What techniques do people use?

like image 480
Chris Muench Avatar asked Mar 29 '11 16:03

Chris Muench


3 Answers

With macos Monterey it seems you should use the following shell command

log show --process cron

you can add --info and/or --debug if required

like image 116
2 revs, 2 users 94% Avatar answered Nov 12 '22 12:11

2 revs, 2 users 94%


I just redirected the output of the cron script >> to a file and that seemed to work well enough.

like image 27
Chris Muench Avatar answered Nov 12 '22 14:11

Chris Muench


tail -f /var/log/syslog | grep CRON

It can happen that "syslog" is not located in "/var/log/", in this case just run the following line to get its location:

whereis syslog
like image 2
vijay Avatar answered Nov 12 '22 12:11

vijay