9 .Nd queue, examine or delete jobs for later execution
23 .Ar MM DD hh mm Op . Ar SS
26 .Fl c Ar job Op Ar job ...
33 .Fl r Ar job Op Ar job ...
54 read commands from standard input or a specified file which are to
55 be executed at a later time, using
57 .Bl -tag -width indent
59 executes commands at a specified time;
61 lists the user's pending jobs, unless the user is the superuser; in that
62 case, everybody's jobs are listed;
66 executes commands when system load levels permit; in other words, when
67 the load average drops below _LOADAVG_MX times number of active CPUs,
68 or the value specified in the invocation of
74 utility allows some moderately complex
77 It accepts times of the form
81 to run a job at a specific time of day.
82 (If that time is already past, the next day is assumed.)
83 As an alternative, the following keywords may be specified:
89 and time-of-day may be suffixed with
93 for running in the morning or the evening.
94 The day on which the job is to be run may also be specified
95 by giving a date in the form
99 or giving a date of the forms
107 The specification of a date must follow the specification of
109 Time can also be specified as:
111 .Cm \&+ Ar count \%time-units ,
112 where the time-units can be
122 may be told to run the job today by suffixing the time with
124 and to run the job tomorrow by suffixing the time with
129 utility also supports the
139 commands are read from standard input or the file specified
143 The working directory, the environment (except for the variables
151 are retained from the time of invocation.
156 command invoked from a
158 shell will retain the current userid.
159 The user will be mailed standard error and standard output from his
161 Mail will be sent using the command
167 shell, the owner of the login shell will receive the mail.
169 The superuser may use these commands in any case.
170 For other users, permission to use
172 is determined by the files
173 .Pa _PERM_PATH/at.allow
175 .Pa _PERM_PATH/at.deny .
178 .Pa _PERM_PATH/at.allow
179 exists, only usernames mentioned in it are allowed to use
181 In these two files, a user is considered to be listed only if the user
182 name has no blank or other characters before it on its line and a
183 newline character immediately after the name, even at the end of
185 Other lines are ignored and may be used for comments.
188 .Pa _PERM_PATH/at.allow
190 .Pa _PERM_PATH/at.deny
191 is checked, every username not mentioned in it is then allowed
195 If neither exists, only the superuser is allowed use of
197 This is the default configuration.
198 .Sh IMPLEMENTATION NOTES
201 is implemented through the
206 This implies that the granularity of
208 might not be optimal for every deployment.
209 If a finer granularity is desired, the
211 file can be edited and will be read by the system crontab, from which
216 environment variables are inherited.
218 .Bl -tag -width indent
220 Use the specified queue.
221 A queue designation consists of a single letter; valid queue designations
231 .Ar _DEFAULT_AT_QUEUE
232 queue is the default for
235 .Ar _DEFAULT_BATCH_QUEUE
238 Queues with higher letters run with increased niceness.
239 If a job is submitted to a queue designated with an uppercase letter, it
240 is treated as if it had been submitted to batch at that time.
243 is given a specific queue, it will only show jobs pending in that queue.
245 Send mail to the user when the job has completed even if there was no
250 rather than standard input.
252 With no arguments, list all jobs for the invoking user.
254 job numbers are given, list only those jobs.
258 (this option is deprecated; use
267 shows completed but not yet deleted jobs in the queue; otherwise
268 shows the time the job will be executed.
270 Cat the jobs listed on the command line to standard output.
272 Remove the specified jobs.
274 Specify the job time using the \*[Px] time format.
275 The argument should be in the form
277 .Op Oo Ar CC Oc Ar YY
278 .Ar MM DD hh mm Op . Ar SS
280 where each pair of letters represents the following:
282 .Bl -tag -width indent -compact -offset indent
284 The first two digits of the year (the century).
286 The second two digits of the year.
288 The month of the year, from 1 to 12.
290 the day of the month, from 1 to 31.
292 The hour of the day, from 0 to 23.
294 The minute of the hour, from 0 to 59.
296 The second of the minute, from 0 to 60.
303 letter pairs are not specified, the values default to the current
307 letter pair is not specified, the value defaults to 0.
310 .Bl -tag -width _ATJOB_DIR/_LOCKFILE -compact
312 directory containing job files
314 directory containing output spool files
315 .It Pa /var/run/utx.active
317 .It Pa _PERM_PATH/at.allow
318 allow permission control
319 .It Pa _PERM_PATH/at.deny
320 deny permission control
321 .It Pa _ATJOB_DIR/_LOCKFILE
322 job-creation lock file
325 To run a job at 4pm three days from now, use:
326 .Bd -literal -offset indent
330 To run a job at 10:00am on July 31, use:
331 .Bd -literal -offset indent
335 To run a job at 1am tomorrow, use:
336 .Bd -literal -offset indent
349 At was mostly written by
350 .An Thomas Koenig Aq Mt ig25@rz.uni-karlsruhe.de .
351 The time parsing routines are by
352 .An David Parsons Aq Mt orc@pell.chi.il.us ,
353 with minor enhancements by
354 .An Joe Halpin Aq Mt joe.halpin@attbi.com .
357 .Pa /var/run/utx.active
358 is not available or corrupted, or if the user is not logged on at the
361 is invoked, the mail is sent to the userid found
362 in the environment variable
364 If that is undefined or empty, the current userid is assumed.
371 as presently implemented are not suitable when users are competing for
373 If this is the case, another batch system such as
375 may be more suitable.
377 Specifying a date past 2038 may not work on some systems.