Imported Upstream version 3.2.0
[debian/amanda] / man / amreport.8
1 '\" t
2 .\"     Title: amreport
3 .\"    Author: Stefan G. Weichinger <sgw@amanda.org>
4 .\" Generator: DocBook XSL Stylesheets vsnapshot_8273 <http://docbook.sf.net/>
5 .\"      Date: 10/18/2010
6 .\"    Manual: System Administration Commands
7 .\"    Source: Amanda 3.2.0
8 .\"  Language: English
9 .\"
10 .TH "AMREPORT" "8" "10/18/2010" "Amanda 3\&.2\&.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 amreport \- generate a formatted output of statistics for an Amanda run
23 .SH "SYNOPSIS"
24 .HP \w'\fBamreport\fR\ 'u
25 \fBamreport\fR [\fIconfig\fR] [\fB\-o\fR\ \fIconfigoption\fR...] [(1)\ \fIcommand\-line options\fR | (2)\ \fIscript options\fR]
26 .it 1 an-trap
27 .nr an-no-space-flag 1
28 .nr an-break-flag 1
29 .br
30 .HP \w'(1)\ 'u
31 (1)\ [\-\-log=\fIlogfile\fR] [\-\-ps=\fIfilename\fR] [\-\-text=\fIfilename\fR] [\-\-xml=\fIfilename\fR] [\-\-print=\fIprinter\fR] [\-\-mail\-text=\fIrecipient\fR]
32 .HP \w'(2)\ 'u
33 (2)\ [\-i] [\-M\ \fIaddress\fR] [\-l\ \fIlogfile\fR] [\-f\ \fIoutputfile\fR] [\-p\ \fIpostscriptfile\fR] [\-\-from\-amdump]
34 .SH "DESCRIPTION"
35 .PP
36 \fBAmreport\fR
37 generates a summary report of an Amanda backup run\&.
38 .PP
39 See the
40 \fBamanda\fR(8)
41 man page for more details about Amanda\&.
42 .SH "OPTIONS"
43 .PP
44 \fIconfig\fR
45 .RS 4
46 Name of the configuration to process\&. If no configuration name is specified, amanda\&.conf is read from the current directory\&.
47 .RE
48 .PP
49 \fB\-o \fR\fB\fIconfigoption\fR\fR
50 .RS 4
51 See the "CONFIGURATION OVERRIDE" section in
52 \fBamanda\fR(8)\&.
53 .RE
54 .PP
55 Amreport operates in two distinct modes\&. Command\-line mode is intended for use by an administrator from the command line, and uses long command\-line options for clarity\&. Script mode is intended for use from scripts such as amdump, and has a lot of non\-obvious default behaviors to suit that need\&.
56 .PP
57 Unless a script\-mode option is given, amreport defaults to command\-line mode\&. If no options are given, amreport writes a report for the most recent logfile to stdout\&.
58 .SS "Command\-Line Mode Options"
59 .PP
60 \fB\-\-log=\fR\fB\fIlogfile\fR\fR
61 .RS 4
62 Use this logfile as the basis for the report\&. If this option is given, then the report is a "historical" report and will not include current state from e\&.g\&., holding disk and curinfo\&. If this option is not specified, then the most recent logfile will be used\&.
63 .RE
64 .PP
65 \fB\-\-ps=\fR\fB\fIfilename\fR\fR
66 .RS 4
67 Write a postscript label to
68 \fIfilename\fR\&. See "LABEL PRINTING" below\&. If filename is not specified, then the label is written to stdout\&.
69 .RE
70 .PP
71 \fB\-\-text=\fR\fB\fIfilename\fR\fR
72 .RS 4
73 Write a human\-readable text report to
74 \fIfilename\fR\&. If filename is not specified, then the report is written to stdout\&.
75 .RE
76 .PP
77 \fB\-\-xml=\fR\fB\fIfilename\fR\fR
78 .RS 4
79 Write an XML\-formatted report to
80 \fIfilename\fR\&. If filename is not specified, then the report is written to stdout\&.
81 .RE
82 .PP
83 \fB\-\-print=\fR\fB\fIprinter\fR\fR
84 .RS 4
85 Pipe a postscript label to
86 \fBlp\fR
87 or
88 \fBlpr\fR, specifying the given
89 \fIprinter\fR\&. If the printer is not specified, uses the default from the Amanda configuration, or the system default printer\&.
90 .RE
91 .PP
92 \fB\-\-mail\-text=\fR\fB\fIrecipient\fR\fR
93 .RS 4
94 Send a human\-readable text report to the given
95 \fIrecipient\fR
96 via the mailer specified in the Amanda configuration\&. If the recipient is not specified, this uses the
97 \fImailto\fR
98 from the Amanda configuration\&.
99 .RE
100 .SS "Script Mode Options"
101 .PP
102 \fB\-i\fR
103 .RS 4
104 Don\'t email the report\&.
105 .RE
106 .PP
107 \fB\-M\fR \fIaddress\fR
108 .RS 4
109 Mail the report to
110 \fIaddress\fR
111 instead of the
112 \fBmailto\fR
113 value from
114 \fIamanda\&.conf\fR\&.
115 .RE
116 .PP
117 \fB\-l\fR \fIlogfile\fR
118 .RS 4
119 Name of the log file to parse to generate the report\&. If a log file is not specified, it defaults to the file
120 $logdir/log, where
121 $logdir
122 is the log directory defined in amanda\&.conf\&.
123 .RE
124 .PP
125 \fB\-f\fR \fIoutputfile\fR
126 .RS 4
127 Normally,
128 \fBamreport\fR
129 sends the report via e\-mail to the
130 \fImailto\fR
131 user as defined in the amanda\&.conf file\&. If
132 \fIoutputfile\fR
133 is specified, then the report is put in
134 \fIoutputfile\fR\&.
135 .RE
136 .PP
137 \fB\-p\fR \fIpostscriptfile\fR
138 .RS 4
139 Send the postscript output to the file
140 \fIpostscriptfile\fR
141 instead of to the
142 \fBlpr\fR(1)
143 command\&. This option has an effect only if the
144 \fIlbl\-templ\fR
145 directive is specified in amanda\&.conf\&.
146 .RE
147 .PP
148 \fB\-\-from\-amdump\fR
149 .RS 4
150 Force script mode\&. Has no other effect\&.
151 .RE
152 .SH "TEXT REPORT FORMAT"
153 .PP
154 Amanda\'s text report format is divided into several sections\&. Some of these sections only appear if they are not empty\&.
155 .PP
156 Although newer versions of Amanda try to use the term "volume" to refer to a unit of storage, amreport still uses the term "tape", even if backups are done to non\-tape devices, to allow scripts which parse amreport\'s output to continue to function\&.
157 .SS "Summary"
158 .nf
159 Hostname: bkserver
160 Org     : DailySet1
161 Config  : Daily
162 Date    : February 25, 2009
163
164 These dumps were to tape Daily\-103\&.
165 The next tape Amanda expects to use is: Daily\-142
166
167 FAILURE DUMP SUMMARY:
168    jamon\&.slikon\&.local /var lev 0  FAILED [/bin/tar exited with status 2]
169 .fi
170 .PP
171 The summary section describes the run in broad terms, giving the server hostname, organization (from the
172 \fBorg\fR
173 configuration parameter), configuration name, and dump date\&. This is followed by a description of the volumes and holding disk used, and an rough estimate of the volume(s) Amanda will use on the next run\&.
174 .PP
175 Brief notices of any unusual circumstances will also be included here\&.
176 .SS "Statistics"
177 .nf
178 STATISTICS:
179                           Total       Full      Incr\&.
180                         \-\-\-\-\-\-\-\-   \-\-\-\-\-\-\-\-   \-\-\-\-\-\-\-\-
181 Estimate Time (hrs:min)    0:00
182 Run Time (hrs:min)         0:01
183 Dump Time (hrs:min)        0:00       0:00       0:00
184 Output Size (meg)           1\&.6        0\&.0        1\&.6
185 Original Size (meg)         1\&.6        0\&.0        1\&.6
186 Avg Compressed Size (%)   100\&.0      100\&.0      100\&.0   (level:#disks \&.\&.\&.)
187 Filesystems Dumped            4          1          3   (1:3)
188 Avg Dump Rate (k/s)      1555\&.1      134\&.2     1787\&.3
189
190 Tape Time (hrs:min)        0:00       0:00       0:00
191 Tape Size (meg)             1\&.6        0\&.0        1\&.6
192 Tape Used (%)               5\&.5        0\&.1        5\&.4   (level:#disks \&.\&.\&.)
193 Filesystems Taped             4          1          3   (1:3)
194                                                         (level:#parts \&.\&.\&.)
195 Parts Taped                   4          1          3   (1:3)
196 Avg Tp Write Rate (k/s)  143966    27624\&.3     151811
197
198 USAGE BY TAPE:
199   Label            Time      Size      %  DLEs Parts
200   metals\-013       0:00     1650k    5\&.4     4     4
201 .fi
202 .PP
203 This section contains aggregate statistics for the entire run\&. The three columns break down the results into a total for all data handled, only full dumps, and only incremental dumps\&. In the right margin, amreport indicates the breakdown of dump levels at the dumper and the taper\&.
204 .PP
205 The rows have the following meanings:
206 .PP
207 Estimate Time
208 .RS 4
209 The time used by the planner to estimate dump sizes\&.
210 .RE
211 .PP
212 Run Time
213 .RS 4
214 Total runtime, from the invocation of amdump to its completion\&.
215 .RE
216 .PP
217 Dump Time
218 .RS 4
219 Total time spent dumping clients\&.
220 .RE
221 .PP
222 Output Size
223 .RS 4
224 Total quantity of data dumped, after compression\&.
225 .RE
226 .PP
227 Original Size
228 .RS 4
229 Total quantity of data dumped, before compression\&.
230 .RE
231 .PP
232 Avg Compressed Size
233 .RS 4
234 Compression ratio, calculated from the previous two rows\&.
235 .RE
236 .PP
237 Filesystems Dumped
238 .RS 4
239 Number of DLEs dumped\&.
240 .RE
241 .PP
242 Avg Dump Rate
243 .RS 4
244 Average speed at which clients produced data\&. Note that, for dumps done directly to a slow device, rather than to holding disk, this rate may reflect a write speed constrained by the device speed\&.
245 .RE
246 .PP
247 Tape Time
248 .RS 4
249 Total time spent writing to storage volumes\&. This includes time spent changing tapes, including time spent waiting for flush thresholds to be met\&.
250 .RE
251 .PP
252 Tape Size
253 .RS 4
254 Total quantity of data written to storage volumes\&.
255 .RE
256 .PP
257 Tape Used
258 .RS 4
259 Fraction of the total allocated storage (tapetype length times runtapes) actually used\&.
260 .RE
261 .PP
262 Filesystems Taped
263 .RS 4
264 Number of filesystems written to storage\&. This may be larger or smaller than the number of filesystems dumped, due to flushes or dumps left on holding disk\&.
265 .RE
266 .PP
267 Parts Taped
268 .RS 4
269 Number of split parts writtten to storage\&. If this number is very large, then the split size may be too small\&.
270 .RE
271 .PP
272 Avg Tp Write Rate
273 .RS 4
274 Taper speed, based on the tape time and tape size, above\&. Note that, because the tape time includes time spent on tasks other than writing to tape, this does not necessary reflect the device\'s real write speed\&. However, the value is useful for capacity planning, as it reflects a realistic estimate of how quickly Amanda can write data to storage\&.
275 .RE
276 .SS "Usage by Tape"
277 .nf
278 USAGE BY TAPE:
279   Label          Time      Size      %  DLEs Parts
280   Conf\-001       0:00    20320k   66\&.2     1     4
281   Conf\-002       0:00     6470k   21\&.1     0     2
282 .fi
283 .PP
284 This short section gives per\-volume statistics: time spent writing to the volume; bytes written to the volume; portion of the expected tape length used; number of DLEs started, and total number of split parts written\&.
285 .SS "Notes"
286 .nf
287 NOTES:
288   taper: tape DAILY\-37 kb 30720 fm 3 [OK]
289 .fi
290 .PP
291 This section contains any informational log messages from the run\&. Most messages are self\-explanatory\&. The taper message shown in the example is always present, and is redundant to the previous section\&. It indicates that 30720 kb were written to "DAILY\-37" in 3 files\&.
292 .SS "Failure and Strange Details"
293 .nf
294 FAILED DUMP DETAILS:
295
296 /\-\-  jamon\&.slikon\&.local /var lev 0 FAILED [/bin/tar exited with status 2]
297 sendbackup: info BACKUP=APPLICATION
298 sendbackup: info APPLICATION=amgtar
299 sendbackup: info RECOVER_CMD=/usr/bin/gzip \-dc |amgtar \-f\&.\&.\&. \-
300 sendbackup: info COMPRESS_SUFFIX=\&.gz
301 sendbackup: info end
302 ? /bin/tar: \&./gdm: Cannot savedir: Permission denied
303 | Total bytes written: 943831040 (901MiB, 4\&.9MiB/s)
304 | /bin/tar: Error exit delayed from previous errors
305 sendbackup: error [/bin/tar exited with status 2]
306 sendbackup: size 921710
307 sendbackup: end
308 \e\e\-\-\-\-\-\-\-\-
309
310 STRANGE DUMP DETAILS:
311
312 /\-\-  bsdfw\&.slikon\&.local / lev 0 STRANGE
313 sendbackup: info BACKUP=APPLICATION
314 sendbackup: info APPLICATION=amgtar
315 sendbackup: info RECOVER_CMD=/usr/bin/gzip \-dc |amgtar \-f\&.\&.\&. \-
316 sendbackup: info COMPRESS_SUFFIX=\&.gz
317 sendbackup: info end
318 | /bin/tar: \&./tmp/\&.X11\-unix/X0: socket ignored
319 | Total bytes written: 5530869760 (5\&.2GiB, 3\&.0MiB/s)
320 sendbackup: size 5401240
321 sendbackup: end
322 \e\e\-\-\-\-\-\-\-\-
323 .fi
324 .PP
325 This section expands on failures and strange results indicated in earlier sections\&. In both cases, the details contain a messages produced by the underlying backup tool \- GNU tar, in this example\&. Failed dumps have actually failed, and the reasons are usually clear\&. Strange dumps, however, are regarded as successful by Amanda, but contain messages that Amanda did not recognize and which may be of interest to the operator\&.
326 .SS "Dump Summary"
327 .nf
328 DUMP SUMMARY:
329                                        DUMPER STATS                TAPER STATS
330 HOSTNAME     DISK        L ORIG\-kB  OUT\-kB  COMP%  MMM:SS   KB/s MMM:SS     KB/s
331 \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
332 strontium    /etc        1     270     270    \-\-     0:00 1146\&.3   0:00 140918\&.6
333 strontium    \-me/elantra 1      10      10    \-\-     0:00   65\&.6   0:00   9033\&.4
334 strontium    /local      0      20      20    \-\-     0:00  133\&.9   0:00  27624\&.3
335 strontium    \-ository_13 1    1350    1350    \-\-     0:01 2568\&.5   0:00 175006\&.5
336 .fi
337 .PP
338 The dump summary table has one row for each DLE processed during the run\&. The "L" column gives the level of the dump\&. The remaining colums are divided into dumper stats and taper stats\&.
339 .PP
340 The dumper stats give the original (before compression) and output (after compression) size of each dump, as well as a compression ratio, if applicable\&. The column labeled "MMM:SS" gives the time spent on that dump, and the next column is the calculated dump rate\&.
341 .PP
342 The taper stats give the time and speed with which the dump was written to storage\&. This value is the sum of the times for each part, and as such does not include time spent switching volumes\&.
343 .SH "LABEL PRINTING"
344 .PP
345 Amanda can print postscript labels describing the contents of tape(s) written in a run\&. The labels are designed to be folded and inserted into the tape case along with the tape or hole punched and put in a 3\-ring binder\&. Various label templates are provided to format data for different tape sizes\&.
346 .PP
347 The information printed varies slightly between label templates due to size constraints\&. Labels contain one line for each host/file\-system pair and may also contain the file number on the tape, the level of the dump, the original size of the dump and the size of the (possibly compressed) tape file\&.
348 .PP
349 Add the
350 \fIlbl\-templ\fR
351 parameter to the tapetype definition in amanda\&.conf to enable labels\&. If you don\'t add this line to your tapetype definition,
352 \fBamreport\fR
353 will not print tape labels\&.
354 .PP
355 You may use the
356 \fIprinter\fR
357 keyword in amanda\&.conf to print to other than the system default printer\&.
358 .SH "TEMPLATES"
359 .PP
360 Amanda provides label templates for the following tape types\&. These are pretty generic labels and should be easy to customize for other tape types or particular site needs\&.
361 .sp
362 .if n \{\
363 .RS 4
364 .\}
365 .nf
366 * ExaByte 8mm tapes
367 * DAT 4mm tapes
368 * DLT tapes
369 * 3\-ring binder
370 .fi
371 .if n \{\
372 .RE
373 .\}
374 .PP
375 The 3\-ring binder type is the most generic\&. It may be used to make a hardcopy log of the tapes\&.
376 .SH "EXIT CODE"
377
378 The exit code of \fBamreport\fR is the ORed value of:
379 .nf
380  0  = success
381  1  = error
382  2  = a dle give strange message
383  4  = a dle failed
384  8  = Don\'t know the status of a dle (RESULT_MISSING in the report)
385  16 = tape error or no more tape
386 .fi
387 .SH "SEE ALSO"
388 .PP
389 \fBamanda\fR(8),
390 \fBamflush\fR(8)
391 .PP
392 The Amanda Wiki:
393 : http://wiki.zmanda.com/
394 .SH "AUTHOR"
395 .PP
396 \fBStefan G\&. Weichinger\fR <\&sgw@amanda\&.org\&>