d3012e03aae8306a8c468389f741d26d3cc3902d
[debian/amanda] / man / amadmin.8
1 '\" t
2 .\"     Title: amadmin
3 .\"    Author: James da Silva <jds@amanda.org>
4 .\" Generator: DocBook XSL Stylesheets vsnapshot_8273 <http://docbook.sf.net/>
5 .\"      Date: 06/01/2010
6 .\"    Manual: System Administration Commands
7 .\"    Source: Amanda 3.1.0
8 .\"  Language: English
9 .\"
10 .TH "AMADMIN" "8" "06/01/2010" "Amanda 3\&.1\&.0" "System Administration Commands"
11 .\" -----------------------------------------------------------------
12 .\" * set default formatting
13 .\" -----------------------------------------------------------------
14 .\" disable hyphenation
15 .nh
16 .\" disable justification (adjust text to left margin only)
17 .ad l
18 .\" -----------------------------------------------------------------
19 .\" * MAIN CONTENT STARTS HERE *
20 .\" -----------------------------------------------------------------
21 .SH "NAME"
22 amadmin \- administrative interface to control Amanda backups
23 .SH "SYNOPSIS"
24 .HP \w'\fBamadmin\fR\ 'u
25 \fBamadmin\fR \fIconfig\fR \fIcommand\fR [\fIcommand_options\fR...] [{\fB\-o\fR\ \fIconfigoption\fR}...]
26 .SH "DESCRIPTION"
27 .PP
28 \fBAmadmin\fR
29 performs various administrative tasks on the
30 \fIconfig\fR
31 Amanda configuration\&.
32 .PP
33 See the
34 \fBamanda\fR(8)
35 man page for more details about Amanda\&.
36 .SH "COMMANDS"
37 .PP
38 Commands that take a
39 \fIhostname\fR
40 [
41 \fIdisks\fR
42 ] parameter pair operate on all disks in the
43 \fBdisklist\fR(5)
44 for that
45 \fIhostname\fR
46 if no disks are specified\&. Where
47 \fIhostname\fR
48 is also marked as being optional, the command operates on all hosts and disks in the
49 \fBdisklist\fR(5)\&. Both
50 \fIhostname\fR
51 and
52 \fIdisks\fR
53 are special expressions; see the "HOST & DISK EXPRESSION" section of
54 \fBamanda\fR(8)
55 for a description\&.
56 .PP
57 Commands that take one or more
58 \fIdumpspec\fR
59 parameters operate on the set of dumps specified by all of the expressions\&. See the "DUMP SPECIFICATIONS" section of
60 \fBamanda\fR(8)
61 for a description\&.
62 .PP
63 \fBversion\fR
64 .RS 4
65 Show the current version and some compile time and runtime parameters\&. The
66 \fIconfig\fR
67 parameter must be present but is ignored\&.
68 .RE
69 .PP
70 \fBestimate\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
71 .RS 4
72 Print the server estimate for the dles, each output lines have the following format:
73 .nf
74   hostname diskname level size
75 .fi
76 .PP
77 hostname
78 .RS 4
79 The quoted hostname
80 .RE
81 .PP
82 diskname
83 .RS 4
84 The quoted diskname
85 .RE
86 .PP
87 level
88 .RS 4
89 The level of the estimate
90 .RE
91 .PP
92 size
93 .RS 4
94 The estimate size in kbytes
95 .RE
96 .RE
97 .PP
98 \fBforce\-bump\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
99 .RS 4
100 Force the
101 \fIdisks\fR
102 on
103 \fIhostname\fR
104 to bump to a new incremental level during the next Amanda run\&.
105 .RE
106 .PP
107 \fBforce\-no\-bump\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
108 .RS 4
109 Force the
110 \fIdisks\fR
111 on
112 \fIhostname\fR
113 to not bump to a new incremental level during the next Amanda run\&.
114 .RE
115 .PP
116 \fBunforce\-bump\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
117 .RS 4
118 Undo a previous
119 \fBforce\-bump\fR
120 or
121 \fBforce\-no\-bump\fR
122 command\&.
123 .RE
124 .PP
125 \fBforce\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
126 .RS 4
127 Force the
128 \fIdisks\fR
129 on
130 \fIhostname\fR
131 to do a full (level 0) backup during the next Amanda run\&.
132 .RE
133 .PP
134 \fBunforce\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
135 .RS 4
136 Undo a previous
137 \fBforce\fR
138 command\&.
139 .RE
140 .PP
141 \fBreuse\fR \fItapelabel\fR [ \&.\&.\&. ]
142 .RS 4
143 The tapes listed will be available for reuse at their point in the tape cycle\&.
144 .RE
145 .PP
146 \fBno\-reuse\fR \fItapelabel\fR [ \&.\&.\&. ]
147 .RS 4
148 The tapes listed will not be reused when their turn comes up again in the tape cycle\&. Note that if this causes the number of reusable tapes to drop below the
149 \fBamanda\&.conf\fR
150 \fItapecycle\fR
151 value, Amanda will request new tapes until the count is satisfied again\&.
152 .sp
153 Tape marked
154 \fIno\-reuse\fR
155 are available for recovery, marking them
156 \fIno\-reuse\fR
157 is a security to be sure amanda will not overwrite them\&.
158 .RE
159 .PP
160 \fBdue\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
161 .RS 4
162 Show when the next full dump is due\&.
163 .RE
164 .PP
165 \fBfind\fR [ \fB\-\-sort\fR \fIhkdlpbfw\fR ] [ \fIhostname\fR [ \fIdisks\fR ]* ]*
166 .RS 4
167 Display all backups currently on tape or in the holding disk\&. The tape label or holding disk filename, file number, and status are displayed\&.
168 .sp
169 The
170 \fB\-\-sort\fR
171 option changes the sort order using the following flags:
172 .sp
173 .nf
174 \fIh\fR: host name
175 \fIk\fR: disk name
176 \fId\fR: dump timestamp
177 \fIl\fR: backup level
178 \fIp\fR: dump part
179 \fIb\fR: tape label
180 \fIf\fR: filenum on tape
181 \fIw\fR: write timestamp
182 .fi
183 .sp
184 An uppercase letter reverses the sort order for that key\&. The default sort order is
185 \fBhkdlpbfw\fR\&.
186 .RE
187 .PP
188 \fBholding delete\fR \fIhostname\fR [ \fIdisk\fR [ \fIdatestamp\fR [ \&.\&. ] ] ]
189 .RS 4
190 Delete holding files matching the given specification\&. At least a hostname must be provided\&.
191 .RE
192 .PP
193 \fBholding list\fR [\-l] [\-d] [ \fIhostname\fR [ \fIdisk\fR [ \fIdatestamp\fR [ \&.\&. ] ] ] ]
194 .RS 4
195 List holding files matching the given specification, or all holding files if no specification is provided\&. With \'\-l\', additional information (size, level, and whether the dump is outdated) is provided\&. With \'\-d\', only outdated dumps are shown\&.
196 .sp
197 An outdated holding file is one which is not required for a restore of the
198 \fImost recent\fR
199 dump\&. Note that outdated dumps may still be required for restores at earlier dates\&. For example, assume that a DLE had a level 0 on Monday, level 1\'s Tuesday through Thursday, and a level 2 on Friday\&. Then the files required for a restore of Fridays (the most recent) dump are those from Monday (level 0), Thursday (level 1), and Friday (level 2)\&. Tuesday and Wednesday\'s files are outdated\&.
200 .RE
201 .PP
202 \fBdelete\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
203 .RS 4
204 Delete the specified
205 \fIdisks\fR
206 on
207 \fIhostname\fR
208 from the Amanda database\&.
209 .if n \{\
210 .sp
211 .\}
212 .RS 4
213 .it 1 an-trap
214 .nr an-no-space-flag 1
215 .nr an-break-flag 1
216 .br
217 .ps +1
218 \fBNote\fR
219 .ps -1
220 .br
221 If you do not also remove the disk from the
222 \fBdisklist\fR(5)
223 file, Amanda will treat it as a new disk during the next run\&.
224 .sp .5v
225 .RE
226 .RE
227 .PP
228 \fBtape\fR
229 .RS 4
230 Display the tape(s) Amanda expects to write to during the next run\&. See also
231 \fBamcheck\fR(8)\&.
232 .RE
233 .PP
234 \fBbumpsize\fR
235 .RS 4
236 Display the current bump threshold parameters, calculated for all backup levels\&.
237 .RE
238 .PP
239 \fBbalance\fR [ \fB\-\-days\fR \fI<num>\fR ]
240 .RS 4
241 Display the distribution of full backups throughout the dump schedule\&.
242 .RE
243 .PP
244 \fBexport\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
245 .RS 4
246 Convert records from the Amanda database to a text format that may be transmitted to another Amanda machine and
247 \fBimport\fRed\&.
248 .RE
249 .PP
250 \fBimport\fR
251 .RS 4
252 Convert
253 \fBexport\fRed records read from standard input to a form Amanda uses and insert them into the database on this machine\&.
254 .RE
255 .PP
256 \fBdisklist\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
257 .RS 4
258 Display the
259 \fBdisklist\fR(5)
260 information for each of the
261 \fIdisks\fR
262 on
263 \fIhostname\fR
264 (or all hosts)\&. Mostly used for debugging\&.
265 .RE
266 .PP
267 \fBinfo\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
268 .RS 4
269 Display the database record for each of the
270 \fIdisks\fR
271 on
272 \fIhostname\fR
273 (or all hosts)\&. Mostly used for debugging\&.
274 .RE
275 .PP
276 \fB\-o \fR\fB\fIconfigoption\fR\fR
277 .RS 4
278 See the "CONFIGURATION OVERRIDE" section in
279 \fBamanda\fR(8)\&.
280 .RE
281 .SH "EXAMPLES"
282 .PP
283 Request three specific file systems on
284 \fImachine\-a\fR
285 get a full level 0 backup during the next Amanda run\&.
286 .nf
287 $ amadmin daily force machine\-a / /var /usr
288 amadmin: machine\-a:/ is set to a forced level 0 tonight\&.
289 amadmin: machine\-a:/var is set to a forced level 0 tonight\&.
290 amadmin: machine\-a:/usr is set to a forced level 0 tonight\&.
291 .fi
292 .PP
293 Request all file systems on
294 \fImachine\-b\fR
295 get a full level 0 backup during the next Amanda run\&.
296 .nf
297 $ amadmin daily force machine\-b
298 amadmin: machine\-b:/ is set to a forced level 0 tonight\&.
299 amadmin: machine\-b:/var is set to a forced level 0 tonight\&.
300 amadmin: machine\-b:/usr is set to a forced level 0 tonight\&.
301 amadmin: machine\-b:/home is set to a forced level 0 tonight\&.
302 .fi
303 .PP
304 Undo the previous
305 \fBforce\fR
306 request for
307 /home
308 on
309 \fImachine\-b\fR\&. The other file systems will still get a full level 0 backup\&.
310 .nf
311 $ amadmin daily unforce machine\-b /home
312 amadmin: force command for machine\-b:/home cleared\&.
313 .fi
314 .PP
315 Locate backup images of
316 /var
317 from
318 \fImachine\-c\fR\&. The
319 \fItape or file\fR
320 column displays either a tape label or a filename depending on whether the image is on tape or is still in the holding disk\&. If the image is on tape, the
321 \fIfile\fR
322 column tells you which file on the tape has the image (file number zero is a tape label)\&. This column shows zero and is not meaningful if the image is still in the holding disk\&. The
323 \fIstatus\fR
324 column tells you whether the backup was successful or had some type of error\&.
325 .nf
326 $ amadmin daily find machine\-c /var
327 date        host      disk lv tape or file                 file part  status
328 2000\-11\-09  machine\-c /var  0 000110                       9   \-\-  OK
329 2000\-11\-08  machine\-c /var  2 000109                       2   \-\-  OK
330 2000\-11\-07  machine\-c /var  2 /amanda/20001107/machine\-c\&._var\&.2  0 OK
331 2000\-11\-06  machine\-c /var  2 000107                       2   \-\-  OK
332 2000\-11\-05  machine\-c /var  2 000106                       3   \-\-  OK
333 2000\-11\-04  machine\-c /var  2 000105                       2   \-\-  OK
334 2000\-11\-03  machine\-c /var  2 000104                       2   \-\-  OK
335 2000\-11\-02  machine\-c /var  2 000103                       2   \-\-  OK
336 2000\-11\-01  machine\-c /var  1 000102                       5   \-\-  OK
337 2000\-10\-31  machine\-c /var  1 000101                       3   \-\-  OK
338 .fi
339 .PP
340 Forget about the
341 /workspace
342 disk on
343 \fImachine\-d\fR\&. If you do not also remove the disk from the
344 \fBdisklist\fR(5)
345 file, Amanda will treat it as a new disk during the next run\&.
346 .nf
347 $ amadmin daily delete machine\-d /workspace
348 amadmin: machine\-d:/workspace deleted from database\&.
349 amadmin: NOTE: you\'ll have to remove these from the \fBdisklist\fR(5) yourself\&.
350 .fi
351 .PP
352 Find the next tape Amanda will use (in this case,
353 123456)\&.
354 .nf
355 $ amadmin daily tape
356 The next Amanda run should go onto tape 123456 or a new tape\&.
357 .fi
358 .PP
359 Show how well full backups are balanced across the dump cycle\&. The
360 \fIdue\-date\fR
361 column is the day the backups are due for a full backup\&.
362 \fI#fs\fR
363 shows the number of filesystems doing full backups that night, and
364 \fIorig KB\fR
365 and
366 \fIout KB\fR
367 show the estimated total size of the backups before and after any compression, respectively\&.
368 .PP
369 The
370 \fIbalance\fR
371 column shows how far off that night\'s backups are from the average size (shown at the bottom of the balance column)\&. Amanda tries to keep the backups within +/\- 5%, but since the amount of data on each filesystem is always changing, and Amanda will never delay backups just to rebalance the schedule, it is common for the schedule to fluctuate by larger percentages\&. In particular, in the case of a tape or backup failure, a bump will occur the following night, which will not be smoothed out until the next pass through the schedule\&.
372 .PP
373 The last line also shows an estimate of how many Amanda runs will be made between full backups for a file system\&. In the example, a file system will probably have a full backup done every eight times Amanda is run (e\&.g\&. every eight days)\&.
374 .nf
375 $ amadmin daily balance
376  due\-date  #fs   orig KB    out KB  balance
377 \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
378 11/10 Mon   21    930389    768753    +5\&.1%
379 11/11 Tue   29   1236272    733211    +0\&.2%
380 11/12 Wed   31   1552381    735796    +0\&.6%
381 11/13 Thu   23   1368447    684552    \-6\&.4%
382 11/14 Fri   32   1065603    758155    +3\&.6%
383 11/15 Sat   14   1300535    738430    +0\&.9%
384 11/16 Sun   31   1362696    740365    +1\&.2%
385 11/17 Mon   30   1427936    773397    +5\&.7%
386 11/18 Tue   11   1059191    721786    \-1\&.3%
387 11/19 Wed   19   1108737    661867    \-9\&.5%
388 \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
389 TOTAL      241  12412187   7316312   731631  (estimated 8 runs per dumpcycle)
390 .fi
391 .SH "FILES"
392 .PP
393 /usr/local/etc/amanda/\fIconfig\fR/amanda\&.conf
394 .SH "SEE ALSO"
395 .PP
396 \fBamanda\fR(8),
397 \fBamanda\fR(8),
398 \fBamcheck\fR(8),
399 \fBamdump\fR(8),
400 \fBamrestore\fR(8),
401 \fBamfetchdump\fR(8)
402 .PP
403 The Amanda Wiki:
404 : http://wiki.zmanda.com/
405 .SH "AUTHORS"
406 .PP
407 \fBJames da Silva\fR <\&jds@amanda\&.org\&>
408 .PP
409 \fBStefan G\&. Weichinger\fR <\&sgw@amanda\&.org\&>