version 1, including all changes.
.
Rev |
Author |
# |
Line |
1 |
perry |
1 |
AT |
|
|
2 |
!!!AT |
|
|
3 |
NAME |
|
|
4 |
SYNOPSIS |
|
|
5 |
DESCRIPTION |
|
|
6 |
OPTIONS |
|
|
7 |
FILES |
|
|
8 |
SEE ALSO |
|
|
9 |
BUGS |
|
|
10 |
AUTHOR |
|
|
11 |
---- |
|
|
12 |
!!NAME |
|
|
13 |
|
|
|
14 |
|
|
|
15 |
at, batch, atq, atrm - queue, examine or delete jobs for later execution |
|
|
16 |
!!SYNOPSIS |
|
|
17 |
|
|
|
18 |
|
|
|
19 |
__at__ [[__-V__] [[__-q__ ''queue''] [[__-f__ |
|
|
20 |
''file''] [[__-mldbv__] __TIME |
|
|
21 |
at -c__ ''job'' [[''job...'']__ |
|
|
22 |
atq__ [[__-V__] [[__-q__ ''queue'']__ |
|
|
23 |
atrm__ [[__-V__] ''job'' [[''job...'']__ |
|
|
24 |
batch__ [[__-V__] [[__-q__ ''queue''] [[__-f__ |
|
|
25 |
''file''] [[__-mv__] [[__TIME__] |
|
|
26 |
!!DESCRIPTION |
|
|
27 |
|
|
|
28 |
|
|
|
29 |
__at__ and __batch__ read commands from standard input |
|
|
30 |
or a specified file which are to be executed at a later |
|
|
31 |
time, using __/bin/sh__. |
|
|
32 |
|
|
|
33 |
|
|
|
34 |
__at__ |
|
|
35 |
|
|
|
36 |
|
|
|
37 |
executes commands at a specified time. |
|
|
38 |
|
|
|
39 |
|
|
|
40 |
__atq__ |
|
|
41 |
|
|
|
42 |
|
|
|
43 |
lists the user's pending jobs, unless the user is the |
|
|
44 |
superuser; in that case, everybody's jobs are listed. The |
|
|
45 |
format of the output lines (one for each job) is: Job |
|
|
46 |
number, date, hour, job class. |
|
|
47 |
|
|
|
48 |
|
|
|
49 |
__atrm__ |
|
|
50 |
|
|
|
51 |
|
|
|
52 |
deletes jobs, identified by their job number. |
|
|
53 |
|
|
|
54 |
|
|
|
55 |
__batch__ |
|
|
56 |
|
|
|
57 |
|
|
|
58 |
executes commands when system load levels permit; in other |
|
|
59 |
words, when the load average drops below 1.5, or the value |
|
|
60 |
specified in the invocation of __atrun__. |
|
|
61 |
|
|
|
62 |
|
|
|
63 |
__At__ allows fairly complex time specifications, |
|
|
64 |
extending the POSIX.2 standard. It accepts times of the form |
|
|
65 |
__HH:MM__ to run a job at a specific time of day. (If |
|
|
66 |
that time is already past, the next day is assumed.) You may |
|
|
67 |
also specify __midnight, noon,__ or __teatime__ (4pm) |
|
|
68 |
and you can have a time-of-day suffixed with __AM__ or |
|
|
69 |
__PM__ for running in the morning or the evening. You can |
|
|
70 |
also say what day the job will be run, by giving a date in |
|
|
71 |
the form __month-name day__ with an optional __year,__ |
|
|
72 |
or giving a date of the form __MMDDYY__ or |
|
|
73 |
__MM/DD/YY__ or __DD.MM.YY.__ The specification of a |
|
|
74 |
date ''must'' follow the specification of the time of |
|
|
75 |
day. You can also give times like __now +__ ''count |
|
|
76 |
time-units,'' where the time-units can be __minutes, |
|
|
77 |
hours, days,__ or __weeks__ and you can tell __at__ |
|
|
78 |
to run the job today by suffixing the time with __today__ |
|
|
79 |
and to run the job tomorrow by suffixing the time with |
|
|
80 |
__tomorrow.__ |
|
|
81 |
|
|
|
82 |
|
|
|
83 |
For example, to run a job at 4pm three days from now, you |
|
|
84 |
would do __at 4pm + 3 days,__ to run a job at 10:00am on |
|
|
85 |
July 31, you would do __at 10am Jul 31__ and to run a job |
|
|
86 |
at 1am tomorrow, you would do __at 1am |
|
|
87 |
tomorrow.__ |
|
|
88 |
|
|
|
89 |
|
|
|
90 |
The exact definition of the time specification can be found |
|
|
91 |
in ''/usr/share/doc/at/timespec''. |
|
|
92 |
|
|
|
93 |
|
|
|
94 |
For both __at__ and __batch__, commands are read from |
|
|
95 |
standard input or the file specified with the __-f__ |
|
|
96 |
option and executed. The working directory, the environment |
|
|
97 |
(except for the variables __TERM__, __DISPLAY__ and |
|
|
98 |
_____) and the umask are retained from the time of |
|
|
99 |
invocation. An __at__ - or __batch__ - command invoked |
|
|
100 |
from a __su(1)__ shell will retain the current userid. |
|
|
101 |
The user will be mailed standard error and standard output |
|
|
102 |
from his commands, if any. Mail will be sent using the |
|
|
103 |
command __/usr/sbin/sendmail__. If __at__ is executed |
|
|
104 |
from a __su(1)__ shell, the owner of the login shell will |
|
|
105 |
receive the mail. |
|
|
106 |
|
|
|
107 |
|
|
|
108 |
The superuser may use these commands in any case. For other |
|
|
109 |
users, permission to use at is determined by the files |
|
|
110 |
''/etc/at.allow'' and ''/etc/at.deny''. |
|
|
111 |
|
|
|
112 |
|
|
|
113 |
If the file ''/etc/at.allow'' exists, only usernames |
|
|
114 |
mentioned in it are allowed to use __at__. |
|
|
115 |
|
|
|
116 |
|
|
|
117 |
If ''/etc/at.allow'' does not exist, ''/etc/at.deny'' |
|
|
118 |
is checked, every username not mentioned in it is then |
|
|
119 |
allowed to use __at__. |
|
|
120 |
|
|
|
121 |
|
|
|
122 |
If neither exists, only the superuser is allowed use of |
|
|
123 |
at. |
|
|
124 |
|
|
|
125 |
|
|
|
126 |
An empty ''/etc/at.deny'' means that every user is |
|
|
127 |
allowed use these commands, this is the default |
|
|
128 |
configuration. |
|
|
129 |
!!OPTIONS |
|
|
130 |
|
|
|
131 |
|
|
|
132 |
__-V__ |
|
|
133 |
|
|
|
134 |
|
|
|
135 |
prints the version number to standard error. |
|
|
136 |
|
|
|
137 |
|
|
|
138 |
__-q__ ''queue'' |
|
|
139 |
|
|
|
140 |
|
|
|
141 |
uses the specified queue. A queue designation consists of a |
|
|
142 |
single letter; valid queue designations range from __a__ |
|
|
143 |
to __z__. and __A__ to __Z__. The __a__ queue is |
|
|
144 |
the default for __at__ and the __b__ queue for |
|
|
145 |
__batch__. Queues with higher letters run with increased |
|
|
146 |
niceness. The special queue |
|
|
147 |
__ |
|
|
148 |
|
|
|
149 |
|
|
|
150 |
If a job is submitted to a queue designated with an |
|
|
151 |
uppercase letter, it is treated as if it had been submitted |
|
|
152 |
to batch at that time. If __atq__ is given a specific |
|
|
153 |
queue, it will only show jobs pending in that |
|
|
154 |
queue. |
|
|
155 |
|
|
|
156 |
|
|
|
157 |
__-m__ |
|
|
158 |
|
|
|
159 |
|
|
|
160 |
Send mail to the user when the job has completed even if |
|
|
161 |
there was no output. |
|
|
162 |
|
|
|
163 |
|
|
|
164 |
__-f__ ''file'' |
|
|
165 |
|
|
|
166 |
|
|
|
167 |
Reads the job from __file__ rather than standard |
|
|
168 |
input. |
|
|
169 |
|
|
|
170 |
|
|
|
171 |
__-l__ |
|
|
172 |
|
|
|
173 |
|
|
|
174 |
Is an alias for __atq.__ |
|
|
175 |
|
|
|
176 |
|
|
|
177 |
__-d__ |
|
|
178 |
|
|
|
179 |
|
|
|
180 |
Is an alias for __atrm.__ |
|
|
181 |
|
|
|
182 |
|
|
|
183 |
__-v__ |
|
|
184 |
|
|
|
185 |
|
|
|
186 |
Shows the time the job will be executed. |
|
|
187 |
|
|
|
188 |
|
|
|
189 |
Times displayed will be in the format |
|
|
190 |
POSIXLY_CORRECT__ is set; then, it will be |
|
|
191 |
__ |
|
|
192 |
|
|
|
193 |
|
|
|
194 |
__-c__ |
|
|
195 |
|
|
|
196 |
|
|
|
197 |
cats the jobs listed on the command line to standard |
|
|
198 |
output. |
|
|
199 |
!!FILES |
|
|
200 |
|
|
|
201 |
|
|
|
202 |
''/var/spool/cron/atjobs |
|
|
203 |
/var/spool/cron/atspool |
|
|
204 |
/proc/loadavg |
|
|
205 |
/var/run/utmp |
|
|
206 |
/etc/at.allow |
|
|
207 |
/etc/at.deny'' |
|
|
208 |
!!SEE ALSO |
|
|
209 |
|
|
|
210 |
|
|
|
211 |
cron(1), nice(1), sh(1), |
|
|
212 |
umask(2), atd(8). |
|
|
213 |
!!BUGS |
|
|
214 |
|
|
|
215 |
|
|
|
216 |
The correct operation of __batch__ for Linux depends on |
|
|
217 |
the presence of a ''proc''- type directory mounted on |
|
|
218 |
''/proc''. |
|
|
219 |
|
|
|
220 |
|
|
|
221 |
If the file ''/var/run/utmp'' is not available or |
|
|
222 |
corrupted, or if the user is not logged on at the time |
|
|
223 |
__at__ is invoked, the mail is sent to the userid found |
|
|
224 |
in the environment variable __LOGNAME__. If that is |
|
|
225 |
undefined or empty, the current userid is |
|
|
226 |
assumed. |
|
|
227 |
|
|
|
228 |
|
|
|
229 |
__At__ and __batch__ as presently implemented are not |
|
|
230 |
suitable when users are competing for resources. If this is |
|
|
231 |
the case for your site, you might want to consider another |
|
|
232 |
batch system, such as __nqs__. |
|
|
233 |
!!AUTHOR |
|
|
234 |
|
|
|
235 |
|
|
|
236 |
At was mostly written by Thomas Koenig, |
|
|
237 |
ig25@rz.uni-karlsruhe.de. |
|
|
238 |
---- |