El fitxer /etc/crontab permet indicar els scripts que s'ha d'executar de forma automàtica cada hora, dia, setmana o mes. A continuació es mostra un exemple del contingut del fitxer /etc/crontab preparat per executar els scripts que hi ha en les carpetes /etc/cron.hourly /etc/cron.daily /etc/cron.weekly i /etc/cron.monthly cada hora, dia, setmana o mes respectivament:

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

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

En aquest exemple:

 
servers/crontab.txt · Darrera modificació: 2008/04/04 17:52 (edició externa)
 
Copyright: Zikzakmedia Llicència Creative Commons By-NC-SA
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki