Imported Upstream version 2.4.5
[debian/amanda] / man / amtoc.8
1 .\"Generated by db2man.xsl. Don't modify this, modify the source.
2 .de Sh \" Subsection
3 .br
4 .if t .Sp
5 .ne 5
6 .PP
7 \fB\\$1\fR
8 .PP
9 ..
10 .de Sp \" Vertical space (when we can't use .PP)
11 .if t .sp .5v
12 .if n .sp
13 ..
14 .de Ip \" List item
15 .br
16 .ie \\n(.$>=3 .ne \\$3
17 .el .ne 3
18 .IP "\\$1" \\$2
19 ..
20 .TH "AMTOC" 8 "" "" ""
21 .SH NAME
22 amtoc \- generate TOC (Table Of Contents) for an AMANDA run
23 .SH "SYNOPSIS"
24 .ad l
25 .hy 0
26 .HP 6
27 \fBamtoc\fR [\-a] [\-i] [\-t] [\-f\ \fIfile\fR] [\-s\ \fIsubs\fR] [\-w] [\-\-] \fIlogfile\fR
28 .ad
29 .hy
30
31 .SH "DESCRIPTION"
32
33 .PP
34 \fBAmtoc\fR generates a table of contents for an \fBAMANDA\fR run\&. It's a perl script (if you don't have perl, install it first!)\&.
35
36 .SH "OPTIONS"
37
38 .TP
39 \fB\-a\fR
40 The output file name will be \fBlabel\-of\-the\-tape\fR\&.toc in the same directory as \fBlogfile\fR\&.
41
42 .TP
43 \fB\-i\fR
44 Display help about \fBamtoc\fR\&.
45
46 .TP
47 \fB\-t\fR
48 Generate the output in tabular form\&.
49
50 .TP
51 \fB\-f file\fR
52 Write the output to a file ('\-' for stdout)\&.
53
54 .TP
55 \fB\-s subs\fR
56 Evaluate the output file name from \fBsubs\fR, with $_ set to \fBlabel\-of\-the\-tape\fR\&. The \fB\-a\fR option is equivalent to \fB\-s\fR  \fI's/$_/\&.toc/'\fR\&.
57
58 .TP
59 \fB\-w\fR
60 Separate tapes with form\-feeds and display blank lines before totals\&.
61
62 .TP
63 \fB\-\-\fR
64 Marks the last option so the next parameter is the \fBlogfile\fR\&.
65
66 .TP
67 \fBlogfile\fR
68 (use '\-' for stdin)
69
70 .SH "OUTPUT FORMAT"
71
72 .PP
73 The standard output has five fields separated by two spaces:
74
75 .nf
76
77 #  Server:/partition  date  level  size[Kb]
78 0  daily\-05:  19991005  \-  \-
79 1  cuisun15:/cuisun15/home  19991005  1  96
80 2  cuinfs:/export/dentiste  19991005  1  96
81   \&.\&.\&.
82 103  cuisg11:/  19991005  0  4139136
83 103  total:  \-  \-  16716288
84
85
86
87 .fi
88
89 .PP
90 In tabular format (\-t), this would look like:
91
92 .nf
93
94   #  Server:/partition           date      lev  size[Kb]
95   0  daily\-05:                   19991005    \-         \-
96   1  cuisun15:/cuisun15/home     19991005    1        96
97   2  cuinfs:/export/dentiste     19991005    1        96
98   \&.\&.\&.
99 103  cuisg11:/                   19991005    0   4139136
100 103  total:                      \-           \-  16716288
101
102
103 .fi
104
105 .SH "USAGE"
106
107 .PP
108 The easiest way to use it is to run \fBamtoc\fR right after \fBamdump\fR in the \fBcron job:\fR
109
110 .nf
111
112 amdump daily ; logdir=`amgetconf daily logdir` ; log=`ls \-1t $logdir/log\&.*\&.[0\-9] | head \-1` ; amtoc \-a $log
113
114 .fi
115
116 .PP
117 which will generate /usr/local/etc/amanda//daily/\fBtape_label\fR\&.toc\&. You may also want to call \fBamtoc\fR after an \fBamflush\fR\&.
118
119 .SH "SEE ALSO"
120
121 .PP
122 \fBamanda\fR(8), \fBamdump\fR(8), \fBamflush\fR(8), \fBamgetconf\fR(8), cron, perl
123
124 .SH "AUTHOR"
125
126 .PP
127 Nicolas Mayencourt <Nicolas\&.Mayencourt@cui\&.unige\&.ch>, University of Geneva/Switzerland : Original text
128
129 .PP
130 Stefan G\&. Weichinger, <sgw@amanda\&.org>, maintainer of the \fBAMANDA\fR\-documentation: XML\-conversion
131