|Welcome to the Monastery|
Cron on Mac OS Xby Ninth Prince (Acolyte)
|on Sep 09, 2008 at 14:36 UTC||Need Help??|
Ninth Prince has asked for the
wisdom of the Perl Monks concerning the following question:
I posted a similar question last week, but this is not a complete re-post. Hopefully, I'm not breaking any etiquette rules.
I am a Perl novice, new to Mac, and have limited and dated experience with UNIX (15 years ago).
I am using Mac OS X 10.5. I want to execute a perl script automatically, once per day, every day. In my previous post it was suggested that I set up a file (called cron.txt and then enter crontab cron.txt in my Terminal.
Okay, so here is what I have done. In my cron.txt file I have the line 21 08 * * * /usr/bin/perl -w /Users/myname/Documents/path/to/CronTest.pl. I copied that "sixth variable" part (the part starting with /usr and all the way through /CronTest.pl) to the command line in my Terminal window and the script executed fine, so I know that command part of the cron listing is correct. (BTW, what is that "sixth variable" called? In my mind I'm calling it the command, but am not sure if this is correct.)
It was 8:19 a.m. when I saved the cron.txt file and still 8:19 when I entered crontab cron.txt. I checked crontab by entering crontab -l and it appeared to be correct. When 8:21 rolled around, however, nothing happened.
Any help would be greatly appreciated. Is there some way that I can check for errors, or see if the line is even executing?
Thanks for your help!