-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcrontabs.4
75 lines (71 loc) · 2.21 KB
/
crontabs.4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
.TH CRONTABS 4 2012-08-29 "Marcela Mašláňová" "Crontabs users' Manual"
.SH NAME
crontabs \- configuration and scripts for running periodical jobs
.SH SYNOPSIS
.B run-parts
.RB [ --list | --test ] \fP\fI<directory>\fP
.br
.SH DESCRIPTION
Crontabs is a historical name for the run-parts script and the system
crontab. The
.B run-parts
command runs all executables in the specified directory.
The execution of files can be allowed or denied by creating file
.B jobs.allow
or
.B jobs.deny
which worked similar as other allow/deny config files. The file must be
created in the specified directory.
.TP
.B --list
print names of all files (not limited to executables), but don't run
them. This option can't be used with
.B test
option.
.TP
.B --test
print names of files, which would be run.
Randomization of jobs can be configured in the
.IR /etc/sysconfig/run-parts
file. To enable randomization of jobs, set the RANDOMIZE parameter to 1
and set the RANDOM parameter to an integer which determines a random
seed. Additionally, you may configure the RANDOMTIME parameter (again,
by specifying an integer) to provide an additional level of
randomization. Jobs are not randomized when the RANDOM and RANDOMTIME
parameters are set to 0. Values in these two parameters must be set to
1 or larger to provide a good enough randomization.
Randomization of cron jobs can be useful for shared networks, where
multiple cron jobs executed at once can cause spikes in traffic,
especially during daily jobs. With randomized jobs, the workload is
evenly distributed throughout the day.
.SH EXAMPLE OF CONFIGURATION FILE
.nf
RANDOMIZE=1
RANDOM=4
RANDOMTIME=8
.fi
.PP
Historically the crontab file contained configuration which called
.B run-parts
on files in
.I cron.{daily,weekly,monthly}
directories. These jobs are now run
indirectly through
.B anacron
to prevent conflicts between
.B cron
and
.B anacron.
That means the
.B anacron
package has to be installed if the jobs in these
directories should be running. Refer to the
.B anacron(8)
how to limit the time of day of the job execution.
.SH EXAMPLE
.I /etc/cron.daily/jobs.deny
could contain for example
.B 0logwatch
which forbid execution of this script.
.SH "SEE ALSO"
.B anacron(8), crontab(5)