Imported Upstream version 2.5.1
[debian/amanda] / man / xml-source / amfetchdump.8.xml
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
3                    "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"
4 [
5   <!-- entities files to use -->
6   <!ENTITY % global_entities SYSTEM '../entities/global.entities'>
7   %global_entities;
8 ]>
9
10 <refentry id='amfetchdump.8'>
11
12 <refmeta>
13 <refentrytitle>amfetchdump</refentrytitle>
14 <manvolnum>8</manvolnum>
15 </refmeta>
16 <refnamediv>
17 <refname>amfetchdump</refname>
18 <refpurpose>extract backup images from multiple &A; tapes.</refpurpose>
19 </refnamediv>
20 <!-- body begins here -->
21 <refsynopsisdiv>
22 <cmdsynopsis>
23   <command>amfetchdump</command>
24     <arg choice='opt'>-pcClawns</arg>
25     <arg choice='opt'>-d <replaceable>device</replaceable></arg>
26     <arg choice='opt'>-O <replaceable>directory</replaceable></arg>
27     <arg choice='opt'>-i <replaceable>logfile</replaceable></arg>
28     <arg choice='opt'>-b <replaceable>blocksize</replaceable></arg>
29     <arg choice='plain'><replaceable>config</replaceable></arg>
30     <arg choice='plain'><replaceable>hostname</replaceable></arg>
31     <arg choice='opt'>
32       <arg choice='plain'><replaceable>disk</replaceable></arg>
33       <arg choice='opt'>
34         <arg choice='plain'><replaceable>date</replaceable></arg>
35         <arg choice='opt'>
36           <arg choice='plain'><replaceable>level</replaceable></arg>
37           <arg choice='opt'>
38             <arg choice='plain'><replaceable>hostname</replaceable></arg>
39             <arg choice='opt'>...</arg>
40           </arg>
41         </arg>
42       </arg>
43     </arg>
44     <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
45 </cmdsynopsis>
46 </refsynopsisdiv>
47
48
49 <refsect1><title>DESCRIPTION</title>
50 <para><emphasis remap='B'>Amfetchdump</emphasis>
51 pulls one or more matching dumps from tape or from the holding disk,
52 handling the reassembly of multi-tape split dump files as well as any
53 tape autochanger operations.</para>
54
55 <para>It will automatically use the logs created by
56 <citerefentry><refentrytitle>amdump</refentrytitle><manvolnum>8</manvolnum></citerefentry>
57 to locate available dumps on tape, in the same way that the <emphasis
58 remap='B'>find</emphasis> feature of
59 <citerefentry><refentrytitle>amadmin</refentrytitle><manvolnum>8</manvolnum></citerefentry>
60 lists available dumps. If these logs are unavailable, it can search
61 tape-by-tape to find what it needs, and can generate new logs to serve
62 as an emergency tape inventory.</para>
63
64 <para>The 
65 <emphasis remap='I'>hostname</emphasis>,
66 <emphasis remap='I'>diskname</emphasis>,
67 <emphasis remap='I'>datestamp</emphasis>,
68 and
69 <emphasis remap='I'>level</emphasis> dump pattern-matching works as in
70 <citerefentry><refentrytitle>amrestore</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
71 with the added requirement that at minimum a <emphasis
72 remap='I'>hostname</emphasis> must be specified when not in inventory mode.</para>
73
74 <para>Unless
75 <option>-p</option>
76 is used, backup images are extracted to files in the current directory named:</para>
77
78 <!-- .RS -->
79 <para><emphasis remap='I'>hostname.diskname.datestamp.dumplevel</emphasis></para>
80 <!-- .RE -->
81 </refsect1>
82
83 <refsect1><title>OPTIONS</title>
84 <variablelist remap='TP'>
85   <varlistentry>
86     <term><option>-p</option></term>
87 <listitem><para>Pipe exactly one complete dump file to <emphasis
88 remap='I'>stdout</emphasis>, instead of writing the file to disk. This
89 will restore only the first matching dumpfile (where
90 &quot;first&quot; is determined by the dump log search
91 facility).</para></listitem>
92   </varlistentry>
93   <varlistentry>
94     <term><option>-d</option> <replaceable>device</replaceable></term>
95 <listitem><para> Restore from this tape device instead of the default.</para></listitem>
96   </varlistentry>
97   <varlistentry>
98     <term><option>-O</option>
99     <replaceable>directory</replaceable></term>
100 <listitem><para>Output restored files to this directory, instead of to the
101     current working directory.</para></listitem>
102   </varlistentry>
103   <varlistentry>
104     <term><option>-c</option></term>
105     <listitem><para>Compress output, fastest method
106     available.</para></listitem>
107   </varlistentry>
108   <varlistentry>
109     <term><option>-C</option></term>
110     <listitem><para>Compress output, smallest file size method
111     available.</para></listitem>
112   </varlistentry>
113   <varlistentry>
114     <term><option>-l</option></term>
115 <listitem><para>Leave dumps in the compressed/uncompressed state in which they
116 were found on tape. By default, <emphasis
117 remap='B'>amfetchdump</emphasis> will automatically uncompress when
118 restoring.</para></listitem>
119   </varlistentry>
120   <varlistentry>
121     <term><option>-a</option></term>
122 <listitem><para>Assume that all tapes are already available, via tape changer or
123 otherwise, instead of prompting the operator to ensure that all tapes
124 are loaded.</para></listitem>
125   </varlistentry>
126   <varlistentry>
127     <term><option>-i</option> <replaceable>filename</replaceable></term>
128 <listitem><para>Generate an inventory of all dumps &quot;seen&quot; on the
129 tapes we search, for later use as a log.</para></listitem>
130   </varlistentry>
131   <varlistentry>
132     <term><option>-w</option></term>
133 <listitem><para>Wait to put split dumps together until all chunks have been
134 restored. Normally, <emphasis remap='B'>amfetchdump</emphasis> will
135 attempt to read pieces of a split file from tape in order, so that it
136 can assemble them simply by appending each file to the first. This
137 option disables the appending behavior, and instead restores each
138 piece as an individual file and reassembles them only after all have
139 been restored.</para>
140
141 <note>This requires at least double the size of your dump in free
142 disk space, in order to build the final assembled dumpfile.</note>
143
144 <para>This behavior is implicitly invoked in circumstances where knowing the
145 location of all dumps on tape in advance is not possible, such as when
146 you are restoring without log files.</para></listitem>
147   </varlistentry>
148   <varlistentry>
149     <term><option>-n</option></term>
150 <listitem><para>Do not reassemble split dump files at all, just restore each
151 piece as an individual file.</para></listitem>
152   </varlistentry>
153   <varlistentry>
154     <term><option>-s</option></term>
155 <listitem><para>Do not fast-forward straight to needed files on tape. This will
156 slow down most restores substantially. Only use this option if your
157 tape drive does not properly support the fast-forward
158 operation.</para></listitem>
159   </varlistentry>
160   <varlistentry>
161     <term><option>-b</option>
162     <replaceable>blocksize</replaceable></term>
163 <listitem><para>Force a particular block size when reading from tapes. This
164     value will usually be autodetected, and should not normally need
165     to be set.</para></listitem>
166   </varlistentry>
167
168   <varlistentry>
169   <term><emphasis remap='B'>-o</emphasis> <replaceable>configoption</replaceable></term>
170   <listitem>
171 <para>See the "<emphasis remap='B'>CONFIGURATION OVERWRITE</emphasis>"
172  section in <citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
173   </listitem>
174   </varlistentry>
175
176 </variablelist>
177 </refsect1>
178
179 <refsect1><title>EXAMPLES</title>
180 <para>All the examples here assume your configuration is called
181 <replaceable>SetA</replaceable>.</para>
182
183 <para>Here's a simple case, restoring all known dumps of the host
184 vanya to the current working directory.</para>
185 <!-- .RS -->
186 <literallayout remap='.nf'>
187 $ amfetchdump SetA vanya
188 </literallayout> <!-- .fi -->
189
190 <para>A more likely scenario involves restoring a particular dump from
191 a particular date. We'll pipe this one to &gnutar; as well, to
192 automatically extract the dump.</para>
193 <!-- .RS -->
194 <literallayout remap='.nf'>
195 $ amfetchdump -p SetA vanya /home 20051020 | gtar -xvpf -
196 </literallayout> <!-- .fi -->
197
198 <para>In a situation where all of our dump logs have been wiped out,
199 we could also use amfetchdump to inventory our tapes and recreate an
200 imitation of those logs, which we'll send to <emphasis
201 remap="I">stdout</emphasis> for casual perusal.
202 <!-- .RS -->
203 <literallayout remap='.nf'>
204 $ amfetchdump -i - SetA
205 </literallayout> <!-- .fi -->
206 </para>
207
208 <para>Note that you can specify a restore while in inventory mode, and
209 <command>amfetchdump</command> will continue searching for more dumps
210 from this host even after successfully restoring a dump, inventorying
211 all the while. If your backup searcher has been trashed, this is a
212 handy way to recover what you have.
213 <!-- .RS -->
214 <literallayout remap='.nf'>
215 $ amfetchdump -i /var/amanda/log SetA backupserver
216 </literallayout> <!-- .fi -->
217 </para>
218 </refsect1>
219
220 <refsect1><title>CAVEATS</title>
221 <command>Amfetchdump</command> is dependent on accessing your server's config,
222 tape changer, and (normally) dump logs. As such, it's not necessarily
223 the most useful tool when those have all been wiped out and you
224 desperately need to pull things from your tape. Pains have been taken
225 to make it as capable as possible, but for seriously minimialist
226 restores, look to
227 <citerefentry><refentrytitle>amrestore</refentrytitle><manvolnum>8</manvolnum></citerefentry>
228 or
229 <citerefentry><refentrytitle>dd</refentrytitle><manvolnum>8</manvolnum></citerefentry>
230 instead.
231 </refsect1>
232
233 <refsect1><title>AUTHOR</title>
234 <para>John Stange, &email.jstange;, National Academies Press</para>
235 <para>Ian Turner, &email.itt;: XML-conversion</para>
236 </refsect1>
237
238 <refsect1><title>SEE ALSO</title>
239 <para><citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
240 <citerefentry><refentrytitle>amadmin</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
241 <citerefentry><refentrytitle>amrestore</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
242 <citerefentry><refentrytitle>tar</refentrytitle><manvolnum>1</manvolnum></citerefentry>
243 <citerefentry><refentrytitle>restore</refentrytitle><manvolnum>8</manvolnum></citerefentry></para>
244 </refsect1>
245 </refentry>
246