Cronjobs

· by

Contents

Cron is a very useful service in Linux systems that allows periodic execution of programs.

Terms

The program that runs other programs periodically is called "cron". The configuration file that tells cron which programs should be run periodically is called "crontab" and is located in /etc/crontab. One line in that file is called a "cronjob". But "crontab" is also a command that lets you add cronjobs.

Example

The following entry in crontab means that uamt.py is executed every day at 3:30 am:

30 3 * * * /home/mthoma/uamt.py

You can check if everything went fine with

mthoma@i13srv30:~> crontab -l
# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.DEZBGc installed on Sat Jan  4 14:35:03 2014)
# (Cronie version 4.2)
30 3 * * * /home/mthoma/uamt.py

Resources