]>
Commit | Line | Data |
---|---|---|
1815bff5 A |
1 | .\" |
2 | .\" Copyright (c) 1993 Christopher G. Demetriou | |
3 | .\" All rights reserved. | |
4 | .\" | |
5 | .\" Redistribution and use in source and binary forms, with or without | |
6 | .\" modification, are permitted provided that the following conditions | |
7 | .\" are met: | |
8 | .\" 1. Redistributions of source code must retain the above copyright | |
9 | .\" notice, this list of conditions and the following disclaimer. | |
10 | .\" 2. Redistributions in binary form must reproduce the above copyright | |
11 | .\" notice, this list of conditions and the following disclaimer in the | |
12 | .\" documentation and/or other materials provided with the distribution. | |
13 | .\" 3. All advertising materials mentioning features or use of this software | |
14 | .\" must display the following acknowledgement: | |
15 | .\" This product includes software developed by Christopher G. Demetriou. | |
16 | .\" 3. The name of the author may not be used to endorse or promote products | |
17 | .\" derived from this software without specific prior written permission | |
18 | .\" | |
19 | .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR | |
20 | .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES | |
21 | .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. | |
22 | .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, | |
23 | .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT | |
24 | .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | |
25 | .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | |
26 | .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | |
27 | .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | |
28 | .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |
29 | .\" | |
30 | .\" $Id: at.1,v 1.1.1.1 1999/05/02 04:21:18 wsanchez Exp $ | |
31 | .\" | |
32 | .Dd December 5, 1993 | |
33 | .Dt "AT" 1 | |
34 | .Os NetBSD 0.9a | |
35 | .Sh NAME | |
36 | .Nm at, batch, atq, atrm | |
37 | .Nd queue, examine, or delete jobs for later execution | |
38 | .\" | |
39 | .Sh SYOPSIS | |
40 | .Nm at | |
41 | .Op Fl q Ar queue | |
42 | .Op Fl f Ar file | |
43 | .Op Fl m | |
44 | .Ar time | |
45 | .Pp | |
46 | .Nm atq | |
47 | .Op Fl q Ar queue | |
48 | .Op Fl v | |
49 | .Pp | |
50 | .Nm atrm | |
51 | .Ar job | |
52 | .Op Ar job ... | |
53 | .Pp | |
54 | .Nm batch | |
55 | .Op Fl f Ar file | |
56 | .Op Fl m | |
57 | .Ar time | |
58 | .Sh DESCRIPTION | |
59 | The | |
60 | .Nm at | |
61 | and | |
62 | .Nm batch | |
63 | utilities read commands from the standard input or a specified file | |
64 | which are to be executed at a later time, using | |
65 | .Xr sh 1 . | |
66 | .Pp | |
67 | The functions of the commands are as follows: | |
68 | .Bl -tag -width indent | |
69 | .It Nm at | |
70 | Executes commands at a specified time. | |
71 | .It Nm atq | |
72 | Lists the user's pending jobs, unless the user is | |
73 | the superuser. In that case, everybody's jobs are | |
74 | listed. | |
75 | .It Nm atrm | |
76 | Deletes jobs. | |
77 | .It Nm batch | |
78 | executes commands when system load levels permit. | |
79 | In other words, it executes the commands when the load | |
80 | average drops below a specified level. | |
81 | .El | |
82 | .Pp | |
83 | For both | |
84 | .Nm at | |
85 | and | |
86 | .Nm batch , | |
87 | the working directory, environment (except for the variables | |
88 | .Nm TERM , | |
89 | .Nm TERMCAP , | |
90 | .Nm DISPLAY , | |
91 | and | |
92 | .Nm _ ) | |
93 | and the umask are retained from the time of invocation. The user | |
94 | will be mailed the standard output and standard error from | |
95 | his commands if any output is generated. If | |
96 | .Nm at | |
97 | is executed from a | |
98 | .Xr su 1 | |
99 | shell, the owner of the login shell will receive the mail. | |
100 | .Sh OPTIONS | |
101 | .Bl -tag -width indent | |
102 | The available options are as follows: | |
103 | .It Fl q Ar queue | |
104 | Use the specified queue. A queue designation consists | |
105 | of a single letter; valid queue designation range from | |
106 | .Ar a | |
107 | to | |
108 | .Ar l . | |
109 | The | |
110 | .Ar a | |
111 | queue is the default, and | |
112 | .Ar b | |
113 | is the batch queue. Queues with higher letters run with | |
114 | increased niceness. If | |
115 | .Nm atq | |
116 | is given a specific queue, it will only show jobs pending | |
117 | in that queue. | |
118 | .It Fl m | |
119 | Send mail to the user when the job has completed, even if | |
120 | there was no output. | |
121 | .It Fl f Ar file | |
122 | Reads the job from | |
123 | .Ar file | |
124 | rather than the standard input. | |
125 | .It Fl v | |
126 | Shows completed but not yet deleted jobs in the queue. | |
127 | .Sh TIME SPECIFICATION | |
128 | .Nm At | |
129 | allows some moderately complex time specifications. | |
130 | It accepts times of the form | |
131 | .Ar HHMM | |
132 | or | |
133 | .Ar HH:MM | |
134 | to run a job at a specific time of day. If | |
135 | that time is already passed, the next day is assumed. | |
136 | You may also specify | |
137 | .Nm midnight , | |
138 | .Nm noon , | |
139 | or | |
140 | .Nm teatime | |
141 | (4PM) and you can give a time of day suffixed with | |
142 | .Nm AM | |
143 | or | |
144 | .Nm PM | |
145 | for running in the morning or the evening. You can | |
146 | also specify the date on which the job will be run | |
147 | by giving a date in the form | |
148 | .Ar month-name day | |
149 | with an optional | |
150 | .Ar year , | |
151 | or giving a date of the form | |
152 | .Ar MMDDYY , | |
153 | .Ar MM/DD/YY | |
154 | or | |
155 | .Ar DD.MM.YY . | |
156 | You can also give times like | |
157 | .Nm now + | |
158 | .Ar count time-units , | |
159 | where the time units can be | |
160 | .Nm minutes, hours, days, | |
161 | or | |
162 | .Nm weeks | |
163 | You can suffix the time with | |
164 | .Nm today | |
165 | to run the job today, or | |
166 | .Nm tomorrow | |
167 | to run the job tomorrow. | |
168 | .Pp | |
169 | For example, to run a job at 4PM three days from now, you | |
170 | would specify a time of | |
171 | .Nm 4PM + 3 days . | |
172 | To run a job at 10:00AM on on July 31, you would specify | |
173 | a time of | |
174 | .Nm 10AM Jul 31 . | |
175 | Finally, to run a job at 1AM tomorrow, you would specify | |
176 | a time of | |
177 | .Nm 1AM tomorrow . | |
178 | .Sh FILES | |
179 | .Bl -tag -width /var/at/lockfile -compact | |
180 | .It Pa /var/at/jobs | |
181 | Directory containing job files | |
182 | .It Pa /var/at/spool | |
183 | Directory containing output spool files | |
184 | .It Pa /var/at/lockfile | |
185 | Job-creation lock file. | |
186 | .It Pa /var/run/utmp | |
187 | .El | |
188 | .Sh SEE ALSO | |
189 | .Xr crond 8 , | |
190 | .Xr nice 1 , | |
191 | .Xr sh 1 , | |
192 | .Xr atrun 8 | |
193 | .Sh AUTHOR | |
194 | .Bl -tag | |
195 | Thomas Koenig, ig25@rz.uni-karlsruhe.de | |
196 | .El | |
197 | .Sh BUGS | |
198 | Traditional access control to | |
199 | .Nm at | |
200 | and | |
201 | .Nm batch | |
202 | via the files | |
203 | .Pa /var/at/at.allow | |
204 | and | |
205 | .Pa /var/at/at.deny | |
206 | is not implemented. | |
207 | .Pp | |
208 | If the file | |
209 | .Pa /var/run/utmp | |
210 | is not available or corrupted, or if the user is not | |
211 | logged in at the time | |
212 | .Nm at | |
213 | is invoked, the mail is sent to the userid found in the | |
214 | environment variable | |
215 | .Nm LOGNAME . | |
216 | If that is undefined or empty, the current userid is assumed. |