Hi guys, how can I set a cronjob on the Fedora 7? I have written the following command in the /etc/crontab file: Code: SHELL=/bin/bash PATH=/sbin:/bin:/usr/sbin:/usr/bin MAILTO=root HOME=/ # php cronjobs #It starts all saturday at 06:00 #* 6 * * 6 lynx -dump http://www.example.com/action.php # The Job starts every day at 05:00. #* 5 * * * lynx -dump http://www.example.com/action1.php # The Job starts every saturday at 04:00 #* 4 * * 6 lynx -dump http://www.example.com/action2.php # The Job start every saturday at 24:00. #* 0 * * 6 lynx -dump http://www.example.com/action3.php # The Job starts at 23:00 of each Saturday #* 23 * * 6 lynx -dump http://www.example.com/action4.php # run-parts 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 ~ ~ but the operations have been repeated many times. which is the mistake? Was I likely wrong with the time settings and the actions are repeated many times? Thanks
Do not edit /etc/crontab file manually. Instead, run the command: crontab -e and insert the line for your cronjob.
The problem is the loop. Maybe there is an error here: * 6 * * 6 lynx -dump http://www.example.com/action.php the first asterix are the minutes. To execute it only one time, have I to set this parameter to zero? thanks