d57ef675a5613bdacf7a8f4ee4b05dbbb49d567e
[debian/amanda] / man / amfetchdump.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 "AMFETCHDUMP" 8 "" "" ""
21 .SH "NAME"
22 amfetchdump - extract backup images from multiple Amanda tapes.
23 .SH "SYNOPSIS"
24 .HP 12
25 \fBamfetchdump\fR [-pcClawns] [-d \fIdevice\fR] [-o \fIdirectory\fR] [-i \fIlogfile\fR] [-b \fIblocksize\fR] \fIconfig\fR \fIhostname\fR [\fIdisk\fR [ \fIdate\fR [ \fIlevel\fR [ \fIhostname\fR [...] ] ] ]]
26 .SH "DESCRIPTION"
27 .PP
28 \fBAmfetchdump\fR
29 pulls one or more matching dumps from tape or from the holding disk, handling the reassembly of multi-tape split dump files as well as any tape autochanger operations.
30 .PP
31 It will automatically use the logs created by
32 \fBamdump\fR(8)
33 to locate available dumps on tape, in the same way that the
34 \fBfind\fR
35 feature of
36 \fBamadmin\fR(8)
37 lists available dumps. If these logs are unavailable, it can search tape-by-tape to find what it needs, and can generate new logs to serve as an emergency tape inventory.
38 .PP
39 The
40 \fBhostname\fR,
41 \fBdiskname\fR,
42 \fBdatestamp\fR, and
43 \fBlevel\fR
44 dump pattern-matching works as in
45 \fBamrestore\fR(8), with the added requirement that at minimum a
46 \fBhostname\fR
47 must be specified when not in inventory mode.
48 .PP
49 Unless
50 \fB-p\fR
51 is used, backup images are extracted to files in the current directory named:
52 .PP
53 \fBhostname.diskname.datestamp.dumplevel\fR
54 .SH "OPTIONS"
55 .TP
56 \fB-p\fR
57 Pipe exactly one complete dump file to
58 \fBstdout\fR, instead of writing the file to disk. This will restore only the first matching dumpfile (where "first" is determined by the dump log search facility).
59 .TP
60 \fB-d\fR \fIdevice\fR
61 Restore from this tape device instead of the default.
62 .TP
63 \fB-o\fR \fIdirectory\fR
64 Output restored files to this directory, instead of to the current working directory.
65 .TP
66 \fB-c\fR
67 Compress output, fastest method available.
68 .TP
69 \fB-C\fR
70 Compress output, smallest file size method available.
71 .TP
72 \fB-l\fR
73 Leave dumps in the compressed/uncompressed state in which they were found on tape. By default,
74 \fBamfetchdump\fR
75 will automatically uncompress when restoring.
76 .TP
77 \fB-a\fR
78 Assume that all tapes are already available, via tape changer or otherwise, instead of prompting the operator to ensure that all tapes are loaded.
79 .TP
80 \fB-i\fR \fIfilename\fR
81 Generate an inventory of all dumps "seen" on the tapes we search, for later use as a log.
82 .TP
83 \fB-w\fR
84 Wait to put split dumps together until all chunks have been restored. Normally,
85 \fBamfetchdump\fR
86 will attempt to read pieces of a split file from tape in order, so that it can assemble them simply by appending each file to the first. This option disables the appending behavior, and instead restores each piece as an individual file and reassembles them only after all have been restored.
87 .sp
88 .it 1 an-trap
89 .nr an-no-space-flag 1
90 .nr an-break-flag 1
91 .br
92 \fBNote\fR
93 This requires at least double the size of your dump in free
94 disk space, in order to build the final assembled dumpfile.This behavior is implicitly invoked in circumstances where knowing the location of all dumps on tape in advance is not possible, such as when you are restoring without log files.
95 .TP
96 \fB-n\fR
97 Do not reassemble split dump files at all, just restore each piece as an individual file.
98 .TP
99 \fB-s\fR
100 Do not fast-forward straight to needed files on tape. This will slow down most restores substantially. Only use this option if your tape drive does not properly support the fast-forward operation.
101 .TP
102 \fB-b\fR \fIblocksize\fR
103 Force a particular block size when reading from tapes. This value will usually be autodetected, and should not normally need to be set.
104 .SH "EXAMPLES"
105 .PP
106 All the examples here assume your configuration is called
107 \fISetA\fR.
108 .PP
109 Here's a simple case, restoring all known dumps of the host vanya to the current working directory.
110 .sp
111 .nf
112
113 $ amfetchdump SetA vanya
114
115 .fi
116 .sp
117 .PP
118 A more likely scenario involves restoring a particular dump from a particular date. We'll pipe this one to
119 \fBGNU-tar\fR
120 as well, to automatically extract the dump.
121 .sp
122 .nf
123
124 $ amfetchdump -p SetA vanya /home 20051020 | gtar -xvpf -
125
126 .fi
127 .sp
128 .PP
129 In a situation where all of our dump logs have been wiped out, we could also use amfetchdump to inventory our tapes and recreate an imitation of those logs, which we'll send to
130 \fBstdout\fR
131 for casual perusal.
132 .sp
133 .nf
134
135 $ amfetchdump -i - SetA
136
137 .fi
138 .sp
139
140 .PP
141 Note that you can specify a restore while in inventory mode, and
142 \fBamfetchdump\fR
143 will continue searching for more dumps from this host even after successfully restoring a dump, inventorying all the while. If your backup searcher has been trashed, this is a handy way to recover what you have.
144 .sp
145 .nf
146
147 $ amfetchdump -i /var/amanda/log SetA backupserver
148
149 .fi
150 .sp
151
152 .SH "CAVEATS"
153 \fBAmfetchdump\fR is dependent on accessing your server's config,
154 tape changer, and (normally) dump logs. As such, it's not necessarily
155 the most useful tool when those have all been wiped out and you
156 desperately need to pull things from your tape. Pains have been taken
157 to make it as capable as possible, but for seriously minimialist
158 restores, look to
159 \fBamrestore\fR(8)
160 or
161 \fBdd\fR(8)
162 instead.
163 .SH "AUTHOR"
164 .PP
165 John Stange,
166 <building@nap.edu>, National Academies Press
167 .PP
168 Ian Turner,
169 <ian@zmanda.com>: XML-conversion
170 .SH "SEE ALSO"
171 .PP
172 \fBamanda\fR(8),
173 \fBamadmin\fR(8),
174 \fBamrestore\fR(8),
175 \fBtar\fR(1)\fBrestore\fR(8)
176