Skip to content

Instantly share code, notes, and snippets.

@alaudet
Last active August 29, 2015 14:05
Show Gist options
  • Save alaudet/a0b868c5e8455d8425a3 to your computer and use it in GitHub Desktop.
Save alaudet/a0b868c5e8455d8425a3 to your computer and use it in GitHub Desktop.
Crontab
# Example of job definition:
# .---------------- minute (0 - 59)
# | .------------- hour (0 - 23)
# | | .---------- day of month (1 - 31)
# | | | .------- month (1 - 12) OR jan,feb,mar,apr ...
# | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat
# | | | | |
# * * * * * user-name command to be executed
Every minute
*/1 * * * * date >> /home/al/crondate
Every hour first minute
01 * * * * date >> /home/al/crondate
Every day at 4:02am
02 4 * * * date >> /home/al/crondate
Every Sunday at 4:22am
22 4 * * 0 date >> /home/al/crondate
Every First of the month at 4:42 am
42 4 1 * * date >> /home/al/crondate
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment