cron(8) - NetBSD Manual Pages

Command: Section: Arch: Collection:  
CRON(8)                 NetBSD System Manager's Manual                 CRON(8)

cron -- daemon to execute scheduled commands (Vixie Cron)
cron [-x debugflags]
cron is normally started during system boot by rc.d(8) framework, if cron is switched on in rc.conf(5). cron searches /var/cron/tabs for crontab files which are named after accounts in /etc/passwd. Crontabs found are loaded into memory. cron also searches for /etc/crontab which is in a different format (see crontab(5)). cron then wakes up every minute, examining all stored crontabs, checking each command to see if it should be run in the current minute. When executing commands, any output is mailed to the owner of the crontab (or to the user named in the MAILTO environment variable in the crontab, if such exists). Events such as START and FINISH are recorded in the /var/log/cron log file with date and time details. This information is useful for a number of reasons, such as determining the amount of time required to run a par- ticular job. By default, root has an hourly job that rotates these log files with compression to preserve disk space. Additionally, cron checks each minute to see if its spool directory's modtime (or the modtime on /etc/crontab) has changed, and if it has, cron will then examine the modtime on all crontabs and reload those which have changed. Thus cron need not be restarted whenever a crontab file is mod- ified. Note that the crontab(1) command updates the modtime of the spool directory whenever it changes a crontab. The -x flag turns on some debugging flags. debugflags is comma-separated list of debugging flags to turn on. If a flag is turned on, cron writes some additional debugging information to system log during its work. Available debugging flags are: sch scheduling proc process control pars parsing load database loading misc miscellaneous test test mode - do not actually execute any commands bit show how various bits are set (long) ext print extended debugging information
/var/cron/tabs cron spool directory /etc/crontab system crontab /var/log/cron log file for cron events
crontab(1), crontab(5)
Paul Vixie <> NetBSD 5.0 December 29, 2007 NetBSD 5.0
Powered by man-cgi (2021-06-01). Maintained for NetBSD by Kimmo Suominen. Based on man-cgi by Panagiotis Christias.