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 peo开发者_运维知识库ple use?
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
I just redirected the output of the cron script >> to a file and that seemed to work well enough.
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
精彩评论