Cron is a repetitive task scheduling system widely used in most Linux systems. Jobs are scheduled via “crontab” files, which contain a line-by-line list of A.) the schedule to execute the job at, and B.) the job itself.
Scheduling syntax
See also
Schedules are composed of 5 space-separated entries:
- Minute
- Hour
- Day
- Month
- Weekday
Each entry may consist of:
*: any value- A numeric value
- A comma-separated list of values
- A dash-separated range of values
- A
/followed by a step value
Examples:
| Schedule | Meaning |
|---|---|
5 4 * * * | At 4:05 |
10 2 1 * * | At 4:05 on the first day of the month |
0 3 * * 1 | At 3:00 on Monday |
5 */4 * * * | 5 minutes past the hour, every 4 hours |