The cron daemon runs recurring jobs defined in crontab files. The five time fields are minute, hour, day of month, month and day of week, so 0 5 * * 1 /usr/local/bin/report.sh runs the script at 05:00 every Monday (day of week 0 is Sunday, 1 is Monday).
Technical Deep Dive: crontab -e edits the invoking user's table, crontab -l lists it, and access is governed by /var/adm/cron/cron.allow and cron.deny. Cron jobs run with a minimal environment, so scripts should use absolute paths and set any required variables; output not redirected is mailed to the owner. The at command runs a job once, and batch runs a job once when system load permits, so neither provides a weekly schedule. Scripts in /etc/rc.d are executed at system startup and shutdown, not on a calendar schedule.
Contribute your Thoughts:
Chosen Answer:
This is a voting comment (?). You can switch to a simple comment. It is better to Upvote an existing comment if you don't have anything to add.
Submit