crontab doesn't work on centos 6

Posted by sbxmal on Server Fault See other posts from Server Fault or by sbxmal
Published on 2012-06-01T10:10:13Z Indexed on 2012/06/01 10:43 UTC
Read the original article Hit count: 249

Filed under:
|

/etc/crontab:

SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
HOME=/

01 * * * * root run-parts /etc/cron.hourly
02 4 * * * root run-parts /etc/cron.daily
22 4 * * 0 root run-parts /etc/cron.weekly
42 4 1 * * root run-parts /etc/cron.monthly

*/2 * * * * /usr/bin/php -q /home/dorsen/public_html/cron-test.php

*/2 * * * * http://www.mysiteurl.com/cron-test.php - also doesn't work

If i run this file directly in browser - all fine

What i did :

root@vded10625 [~]# yum remove cronie-anacron
....
Complete!

root@vded10625 [~]# yum install cronie-noanacron sysstat
....
Complete!

root@vded10625 [~]# service crond start
Starting crond: [ OK ]
root@vded10625 [~]# chkconfig crond on

root@vded10625 [~]# service crond restart
Stopping crond: [ OK ]
Starting crond: [ OK ]

Will be pleased for any help

© Server Fault or respective owner

Related posts about cron

Related posts about centos6