Difference between revisions of "Crontab"
From Linuxintro
imported>ThorstenStaerk (New page: crontab is a configuration file in the /etc folder that tells the cron daemon when to perform what commands. It can look like this: */10 * * * * fetchmail -p pop3 -u 612696 -v pop.gmx...) |
imported>ThorstenStaerk |
||
(6 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
[[crontab]] is a configuration file in the /etc folder that tells the cron daemon when to perform what commands. It can look like this: | [[crontab]] is a configuration file in the /etc folder that tells the cron daemon when to perform what commands. It can look like this: | ||
+ | # Sample crontab file | ||
+ | |||
*/10 * * * * fetchmail -p pop3 -u 612696 -v pop.gmx.net | */10 * * * * fetchmail -p pop3 -u 612696 -v pop.gmx.net | ||
+ | A line starting with a # is a comment. The other line in this example follows the form | ||
+ | <minute> <hour> <day of month> <month> <day of week> [user] <command> | ||
+ | where [user] is optional. | ||
+ | |||
+ | = Examples = | ||
+ | Run the command fetchmail every day at 10 minutes past 1: | ||
+ | 10 1 * * * fetchmail | ||
+ | Run the command fetchmail every day and hour at 10 minutes past the hour: | ||
+ | 10 * * * * fetchmail | ||
+ | Run the command fetchmail every 10 minutes: | ||
+ | */10 * * * * fetchmail | ||
= See also = | = See also = | ||
− | * [http:// | + | * [http://www.manpagez.com/man/5/crontab/ crontab's man page] |
Latest revision as of 08:44, 24 April 2014
crontab is a configuration file in the /etc folder that tells the cron daemon when to perform what commands. It can look like this:
# Sample crontab file */10 * * * * fetchmail -p pop3 -u 612696 -v pop.gmx.net
A line starting with a # is a comment. The other line in this example follows the form
<minute> <hour> <day of month> <month> <day of week> [user] <command>
where [user] is optional.
Examples
Run the command fetchmail every day at 10 minutes past 1:
10 1 * * * fetchmail
Run the command fetchmail every day and hour at 10 minutes past the hour:
10 * * * * fetchmail
Run the command fetchmail every 10 minutes:
*/10 * * * * fetchmail