command to runI am using ubuntu 12 and lamp server . I want to run a php script after every 1 hour . i have create a crontab to execute this and if i check my cron list with
To find out what is wrong with your cron you can type the following command in your terminal:
grep -i "cron1.php" /var/log/syslog
The syslog contains all log of crons.
Try run the code /usr/bin/php5 -q /var/www/cronjobs/cron1.php on terminal to check if there are errors.
You can also redirect all errors to a file:
0 * * * * /usr/bin/php5 -q /var/www/cronjobs/cron1.php 2> /tmp/errorCron1.txt