OSDN Git Service

Fix no pic
[uclinux-h8/uClinux-dist.git] / user / at / at.1.in
1 .Id $Id: at.1.in,v 1.7 1997/03/13 00:15:13 ig25 Exp $
2 .TH AT 1 "Nov 1996" local "Linux Programmer's Manual"
3 .SH NAME
4 at, batch, atq, atrm \- queue, examine or delete jobs for later execution
5 .SH SYNOPSIS
6 .B at
7 .RB [ -V ]
8 .RB [ -q 
9 .IR queue ]
10 .RB [ -f
11 .IR file ]
12 .RB [ -mldbv ]
13 .B TIME
14 .br
15 .B "at -c"
16 .I job
17 .RI [ job... ]
18 .br
19 .B atq
20 .RB [ -V ]
21 .RB [ -q
22 .IR queue ]
23 .RB [ -v ]
24 .br
25 .B atrm
26 .RB [ -V ]
27 .I job
28 .RI [ job... ]
29 .br
30 .B batch
31 .RB [ -V ]
32 .RB [ -q
33 .IR queue ]
34 .RB [ -f
35 .IR file ]
36 .RB [ -mv ]
37 .RB [ TIME ]
38 .SH DESCRIPTION
39 .B at
40 and
41 .B batch
42 read commands from standard input or a specified file which are to
43 be executed at a later time, using
44 .BR /bin/sh .
45 .TP 8
46 .BR at
47 executes commands at a specified time.
48 .TP 8
49 .BR atq
50 lists the user's pending jobs, unless the user is the superuser; in that
51 case, everybody's jobs are listed.
52 .TP 8
53 .BR atrm
54 deletes jobs.
55 .TP 8
56 .BR batch
57 executes commands when system load levels permit; in other words, when the load average
58 drops below @LOADAVG_MX@, or the value specified in the invocation of
59 .BR atrun .
60 .PP
61 .B At
62 allows fairly complex time
63 specifications, extending the POSIX.2 standard.  It accepts times
64 of the form 
65 .B HH:MM
66 to run a job at a specific time of day.
67 (If that time is already past, the next day is assumed.)
68 You may also specify
69 .B midnight,
70 .B noon,
71 or
72 .B teatime
73 (4pm)
74 and you can have a time-of-day suffixed with
75 .B AM
76 or
77 .B PM
78 for running in the morning or the evening.
79 You can also say what day the job will be run,
80 by giving a date in the form
81 .B month-name
82 .B day
83 with an optional
84 .B year,
85 or giving a date of the form
86 .B MMDDYY
87 or
88 .B MM/DD/YY
89 or
90 .B DD.MM.YY.
91 The specification of a date
92 .I must
93 follow the specification of the time of day.
94 You can also give times like
95 .B now
96 .B \+
97 .I count
98 .I time-units,
99 where the time-units can be
100 .B minutes,
101 .B hours,
102 .B days,
103 or
104 .B weeks
105 and you can tell
106 .B at
107 to run the job today by suffixing the time with
108 .B today
109 and to run the job tomorrow by suffixing the time with
110 .B tomorrow.
111 .PP
112 For example, to run a job at 4pm three days from now, you would do
113 .B at 4pm + 3 days,
114 to run a job at 10:00am on July 31, you would do
115 .B at 10am Jul 31
116 and to run a job at 1am tomorrow, you would do
117 .B at 1am tomorrow.
118 .PP
119 The exact definition of the time specification can be found in
120 .IR @prefix@/doc/at/timespec .
121 .PP
122 For both
123 .BR at " and " batch ,
124 commands are read from standard input or the file specified
125 with the
126 .B -f
127 option and executed.
128 The working directory, the environment (except for the variables
129 .BR TERM ,
130 .BR DISPLAY
131 and
132 .BR _ )
133 and the umask are retained from the time of invocation.
134 An
135 .BR "at " \-
136 or
137 .BR "batch "\-
138 command invoked from a 
139 .B su(1)
140 shell will retain the current userid.
141 The user will be mailed standard error and standard output from his
142 commands, if any.
143 Mail will be sent using the command
144 .BR @MAIL_CMD@ .
145 If
146 .B at
147 is executed from a 
148 .B su(1)
149 shell, the owner of the login shell will receive the mail.
150 .PP
151 The superuser may use these commands in any case.
152 For other users, permission to use at is determined by the files
153 .I @ETCDIR@/at.allow
154 and
155 .IR @ETCDIR@/at.deny .
156 .PP
157 If the file
158 .I @ETCDIR@/at.allow
159 exists, only usernames mentioned in it are allowed to use
160 .BR at .
161 .PP
162 If
163 .I @ETCDIR@/at.allow
164 does not exist,
165 .I @ETCDIR@/at.deny
166 is checked, every username not mentioned in it is then allowed
167 to use
168 .BR at .
169 .PP
170 If neither exists, only the superuser is allowed use of at.
171 .PP
172 An empty 
173 .I @ETCDIR@/at.deny
174 means that every user is allowed use these commands, this is the
175 default configuration.
176 .SH OPTIONS
177 .TP 8
178 .B -V
179 prints the version number to standard error.
180 .TP 8
181 .BI \-q " queue"
182 uses the specified queue.
183 A queue designation consists of a single letter; valid queue designations
184 range from
185 .B a
186 to 
187 .BR z .
188 and
189 .B A
190 to
191 .BR Z .
192 The
193 .B @DEFATQ@
194 queue is the default for
195 .B at
196 and the
197 .B @DEFBQ@
198 queue for
199 .BR batch .
200 Queues with higher letters run with increased niceness.  The special
201 queue "=" is reserved for jobs which are currently running.
202 .P
203 If a job is submitted to a queue designated with an uppercase letter, it
204 is treated as if it had been submitted to batch at that time.
205 If
206 .BR atq
207 is given a specific queue, it will only show jobs pending in that queue.
208 .TP 8
209 .B \-m
210 Send mail to the user when the job has completed even if there was no
211 output.
212 .TP 8
213 .BI \-f " file"
214 Reads the job from
215 .BI file
216 rather than standard input.
217 .TP 8
218 .B \-l
219 Is an alias for
220 .B atq.
221 .TP
222 .B \-d
223 Is an alias for
224 .B atrm.
225 .TP
226 .TP
227 .B \-v
228 For
229 .BR atq ,
230 shows completed but not yet deleted jobs in the queue; otherwise
231 shows the time the job will be executed.
232 .P
233 Times displayed will be in the format "1997-02-20 14:50" unless the
234 environment variable
235 .B POSIXLY_CORRECT 
236 is set; then, it will be "Thu Feb 20 14:50:00 1996".
237 .TP
238 .B
239 \-c
240 cats the jobs listed on the command line to standart output.
241 .SH FILES
242 .I @ATJBD@
243 .br
244 .I @ATSPD@
245 .br
246 .I /proc/loadavg
247 .br
248 .I /var/run/utmp
249 .br
250 .I @ETCDIR@/at.allow
251 .br
252 .I @ETCDIR@/at.deny
253 .SH SEE ALSO
254 cron(1), nice(1), sh(1), umask(2), atd(8)
255 .SH BUGS
256 The correct operation of
257 .B batch
258 for Linux depends on the presence of a
259 .IR proc -
260 type directory mounted on
261 .IR /proc .
262 .PP
263 If the file
264 .I /var/run/utmp
265 is not available or corrupted, or if the user is not logged on at the
266 time 
267 .B at
268 is invoked, the mail is sent to the userid found
269 in the environment variable
270 .BR LOGNAME .
271 If that is undefined or empty, the current userid is assumed.
272 .PP
273 .B At
274 and
275 .B batch
276 as presently implemented are not suitable when users are competing for
277 resources.
278 If this is the case for your site, you might want to consider another
279 batch system, such as
280 .BR nqs .
281 .SH AUTHOR
282 At was mostly written by Thomas Koenig, ig25@rz.uni-karlsruhe.de.