Cron Jobs Tips
From AWBS Wiki
There are different options you can use in your cron job setup that will ensure they are all running successfully.
ALWAYS Setup setup your Crontab with an E-Mail address to mail to if there is errors!
Identifying your PHP version and Location for cron jobs
This is important to check, as a good majority of servers are running 2 versions of PHP, your cron jobs could be using a different version then your website.
PHP Version Check
- . Make sure an e-mail address is set for your cron jobs.
- . Create a new cron command. Set it to run every 2 minutes ie */2 in the minute field on most Hosting Panels.
- . In the command field enter PHP -v
- . Save and wait a minute or two, then check the e-mail you specified in step 1. Keep checking until you get an e-mail from your Cron job.
- . Delete the cron job you created for this so you don't receive any more e-mails.
- . Read the e-mail received to see the PHP version being used by the cron jobs.
Location of PHP
Use the same method as in PHP Version Check, but use the command which php'