The crontab (short for "cron table") is a list of commands that are scheduled to run at regular time intervals on your computer system. The crontab command opens the crontab for editing, and lets you add, remove, or modify scheduled tasks.
The daemon which reads the crontab and executes the commands at the right time is called cron. It's named after Kronos, the Greek god of time
Command syntax
crontab [-u user] file
crontab [-u user] [-l | -r | -e] [-i] [-s]
Options
file | Load the crontab data from the specified file. If file is a dash ("-"), the crontab data is read from standard input. |
-u user | Specifies the user whose crontab is to be viewed or modified. If this option is not given, crontab opens the crontab of the user who ran crontab. Note: using su to switch users can confuse crontab, so if you are running it inside of su, always use the -u option to avoid ambiguity. |
-l | Display the current crontab. |
-r | Remove the current crontab. |
-e | Edit the current crontab, using the editor specified in the environment variable VISUALor EDITOR. |
-i | Same as -r, but gives the user a yes/no confirmation prompt before removing the crontab. |
-s | SELinux only: appends the current SELinux security context string as an MLS_LEVELsetting to the crontab file before editing or replacement occurs. See your SELinux documentation for detailed information. |
Find more details here: ucrontab
No comments:
Post a Comment