xml-docbook-documentation-first-pass-20060915
[openafs.git] / doc / xml / AdminReference / sect8 / backup_diskrestore.xml
diff --git a/doc/xml/AdminReference/sect8/backup_diskrestore.xml b/doc/xml/AdminReference/sect8/backup_diskrestore.xml
new file mode 100644 (file)
index 0000000..e6b2948
--- /dev/null
@@ -0,0 +1,329 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<refentry id="backup_diskrestore8">
+  <refmeta>
+    <refentrytitle>backup diskrestore</refentrytitle>
+    <manvolnum>8</manvolnum>
+  </refmeta>
+  <refnamediv>
+    <refname>backup diskrestore</refname>
+    <refpurpose>Restores the entire contents of a partition</refpurpose>
+  </refnamediv>
+  <refsect1>
+    <title>Synopsis</title>
+    <para><emphasis role="bold">backup diskrestore</emphasis> <emphasis role="bold">-server</emphasis> &lt;<emphasis>machine to restore</emphasis>&gt;
+        <emphasis role="bold">-partition</emphasis> &lt;<emphasis>partition to restore</emphasis>&gt;
+        [<emphasis role="bold">-portoffset</emphasis> &lt;<emphasis>TC port offset</emphasis>&gt;+]
+        [<emphasis role="bold">-newserver</emphasis> &lt;<emphasis>destination machine</emphasis>&gt;]
+        [<emphasis role="bold">-newpartition</emphasis> &lt;<emphasis>destination partition</emphasis>&gt;]
+        [<emphasis role="bold">-extension</emphasis> &lt;<emphasis>new volume name extension</emphasis>&gt;]
+        [<emphasis role="bold">-n</emphasis>] [<emphasis role="bold">-localauth</emphasis>] [<emphasis role="bold">-cell</emphasis> &lt;<emphasis>cell name</emphasis>&gt;] [<emphasis role="bold">-help</emphasis>]</para>
+
+    <para><emphasis role="bold">backup di</emphasis> <emphasis role="bold">-s</emphasis> &lt;<emphasis>machine to restore</emphasis>&gt; <emphasis role="bold">-pa</emphasis> &lt;<emphasis>partition to restore</emphasis>&gt;
+        [<emphasis role="bold">-po</emphasis> &lt;<emphasis>TC port offset</emphasis>&gt;+] [<emphasis role="bold">-news</emphasis> &lt;<emphasis>destination machine</emphasis>&gt;]
+        [<emphasis role="bold">-newp</emphasis> &lt;<emphasis>destination partition</emphasis>&gt;]
+        [<emphasis role="bold">-e</emphasis> &lt;<emphasis>new volume name extension</emphasis>&gt;] [<emphasis role="bold">-n</emphasis>] [<emphasis role="bold">-l</emphasis>]
+        [<emphasis role="bold">-c</emphasis> &lt;<emphasis>cell name</emphasis>&gt;] [<emphasis role="bold">-h</emphasis>]</para>
+
+  </refsect1>
+  <refsect1>
+    <title>Description</title>
+    <para>The <emphasis role="bold">backup diskrestore</emphasis> command restores all of the volumes for which
+    the Volume Location Database (VLDB) lists a read/write site on the
+    partition specified with the <emphasis role="bold">-server</emphasis> and <emphasis role="bold">-partition</emphasis> arguments. It is
+    useful if a disk or machine failure corrupts or destroys the data on an
+    entire partition. (To restore any read-only or backup volumes that resided
+    on the partition, use the <emphasis role="bold">vos release</emphasis> and <emphasis role="bold">vos backup</emphasis> commands,
+    respectively, after restoring the read/write version.)</para>
+
+    <para>If restoring only selected volumes to a single site, it is usually more
+    efficient to use the <emphasis role="bold">backup volrestore</emphasis> command. To restore multiple
+    volumes to many different sites, use the <emphasis role="bold">backup volsetrestore</emphasis> command.</para>
+
+    <para>(If the <computeroutput>FILE YES</computeroutput> instruction appears in the
+    <replaceable>/usr/afs/backup/CFG_</replaceable><emphasis>device_name</emphasis><replaceable></replaceable> file on the Tape Coordinator machine
+    associated with the specified port offset, then the Backup System restores
+    data from the backup data file listed for that port offset in the Tape
+    Coordinator's <replaceable>/usr/afs/backup/tapeconfig</replaceable> file, instead of from
+    tape. For the sake of clarity, the following text refers to tapes only,
+    but the Backup System handles backup data files in much the same way.)</para>
+
+    <para>The Backup System determines whether the read/write or backup version of
+    each volume was dumped more recently, and restores the dumps of that
+    version, starting with the most recent full dump. It resets the creation
+    timestamp of each restored volume to the date and time at which it begins
+    restoring the volume (the creation timestamp appears in the <computeroutput>Creation</computeroutput>
+    field of the output from the <emphasis role="bold">vos examine</emphasis> and <emphasis role="bold">vos listvol</emphasis> commands).</para>
+
+    <para>If all of the full and incremental dumps of all relevant volumes were not
+    written on compatible tape devices, use the <emphasis role="bold">-portoffset</emphasis> argument to
+    list multiple port offset numbers in the order in which the tapes are
+    needed (first list the port offset for the full dump, second the port
+    offset for the level 1 incremental dump, and so on). This implies that the
+    full dumps of all relevant volumes must have been written to a type of
+    tape that the first Tape Coordinator can read, the level 1 incremental
+    dumps to a type of tape the second Tape Coordinator can read, and so
+    on. If dumps are on multiple incompatible tape types, use the <emphasis role="bold">backup
+    volrestore</emphasis> command to restore individual volumes, or the <emphasis role="bold">backup
+    volsetrestore</emphasis> command after defining groups of volumes that were dumped
+    to compatible tape types. For further discussion, see the <emphasis>IBM AFS
+    Administration Guide</emphasis>.</para>
+
+    <para>By default, the Backup System restores the contents of the specified
+    partition to that same partition. To restore the contents to an alternate
+    site, combine the following options as indicated. The Backup System
+    removes each volume from the original site, if it still exists, and
+    records the change of site in the VLDB.</para>
+
+    <itemizedlist>
+      <listitem>
+        <para>To restore to a different partition on the same file server machine,
+        provide the <emphasis role="bold">-newpartition</emphasis> argument.</para>
+
+      </listitem>
+      <listitem>
+        <para>To restore to the partition with the same name on a different file server
+        machine, provide the <emphasis role="bold">-newserver</emphasis> argument.</para>
+
+      </listitem>
+      <listitem>
+        <para>To restore to a completely different site, combine the <emphasis role="bold">-newserver</emphasis> and
+        <emphasis role="bold">-newpartition</emphasis> arguments.</para>
+
+      </listitem>
+    </itemizedlist>
+    <para>By default, the Backup System overwrites the contents of existing volumes
+    with the restored data. To create a new volume to house the restored data
+    instead, use the <emphasis role="bold">-extension</emphasis> argument. The Backup System creates the new
+    volume at the site designated by the <emphasis role="bold">-newserver</emphasis> and <emphasis role="bold">-newpartition</emphasis>
+    arguments if they are used or the <emphasis role="bold">-server</emphasis> and <emphasis role="bold">-partition</emphasis> arguments
+    otherwise. It derives the volume name by adding the extension to the
+    read/write base name listed in the VLDB, and creates a new VLDB entry. The
+    command does not affect the existing volume in any way. However, if a
+    volume with the specified extension also already exists, the command
+    overwrites it.</para>
+
+    <para>To print out a list of the tapes containing the needed dumps, without
+    actually performing the restore operation, include the <emphasis role="bold">-n</emphasis> flag along
+    with the other options to be used on the actual command.</para>
+
+    <para>The Tape Coordinator's default response to this command is to access the
+    first tape it needs by invoking the <computeroutput>MOUNT</computeroutput> instruction in the local
+    <replaceable>CFG_</replaceable><emphasis>device_name</emphasis><replaceable></replaceable> file, or by prompting the backup operator to insert
+    the tape if there is no <computeroutput>MOUNT</computeroutput> instruction. However, if the <computeroutput>AUTOQUERY
+    NO</computeroutput> instruction appears in the <replaceable>CFG_</replaceable><emphasis>device_name</emphasis><replaceable></replaceable> file, or if the
+    issuer of the <emphasis role="bold">butc</emphasis> command included the <emphasis role="bold">-noautoquery</emphasis> flag, the Tape
+    Coordinator instead expects the tape to be in the device already.  If it
+    is not, or is the wrong tape, the Tape Coordinator invokes the <computeroutput>MOUNT</computeroutput>
+    instruction or prompts the operator. It also invokes the <computeroutput>MOUNT</computeroutput>
+    instruction or prompts for any additional tapes needed to complete the
+    restore operation; the backup operator must arrange to provide them.</para>
+
+  </refsect1>
+  <refsect1>
+    <title>Cautions</title>
+    <para>If issuing this command to recover data after a disk crash or other
+    damage, be sure not to issue the <emphasis role="bold">vos syncserv</emphasis> command first. Doing so
+    destroys the VLDB record of the volumes that resided on the partition.</para>
+
+  </refsect1>
+  <refsect1>
+    <title>Options</title>
+    <variablelist>
+      <varlistentry>
+        <term><emphasis role="bold">-server</emphasis> &lt;<emphasis>machine to restore</emphasis>&gt;</term>
+        <listitem>
+          <para>Names the file server machine that the VLDB lists as the site of the
+          volumes that need to be restored.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-partition</emphasis> &lt;<emphasis>partition to restore</emphasis>&gt;</term>
+        <listitem>
+          <para>Names the partition that the VLDB lists as the site of the volumes that
+          need to be restored.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-portoffset</emphasis> &lt;<emphasis>TC port offset</emphasis>&gt;+</term>
+        <listitem>
+          <para>Specifies one or more port offset numbers (up to a maximum of 128), each
+          corresponding to a Tape Coordinator to use in the operation. If there is
+          more than one value, the Backup System uses the first one when restoring
+          the full dump of each volume, the second one when restoring the level 1
+          incremental dump of each volume, and so on. It uses the final value in the
+          list when restoring dumps at the corresponding depth in the dump hierarchy
+          and at all lower levels.</para>
+
+          <para>Provide this argument unless the default value of 0 (zero) is appropriate
+          for all dumps. If <computeroutput>0</computeroutput> is just one of the values in the list, provide it
+          explicitly in the appropriate order.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-newserver</emphasis> &lt;<emphasis>destination machine</emphasis>&gt;</term>
+        <listitem>
+          <para>Names an alternate file server machine to which to restore the volumes. If
+          this argument is omitted, the volumes are restored to the file server
+          machine named by the <emphasis role="bold">-server</emphasis> argument.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-newpartition</emphasis> &lt;<emphasis>destination partition</emphasis>&gt;</term>
+        <listitem>
+          <para>Names an alternate partition to which to restore the data. If this
+          argument is omitted, the volumes are restored to the partition named by
+          the <emphasis role="bold">-partition</emphasis> argument.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-extension</emphasis> &lt;<emphasis>new volume name extension</emphasis>&gt;</term>
+        <listitem>
+          <para>Creates a new volume for each volume being restored, to house the restored
+          data. The Backup System derives the new volume's name by appending the
+          specified string to the read/write base name listed in the VLDB, and
+          creates a new VLDB volume entry. The Backup System preserves the contents
+          of the volumes on the partition, if any still exist. Any string other than
+          <computeroutput>.readonly</computeroutput> or <computeroutput>.backup</computeroutput> is acceptable, but the combination of the base
+          name and extension cannot exceed 22 characters in length. To use a period
+          to separate the extension from the name, specify it as the first character
+          of the string (as in <computeroutput>.rst</computeroutput>, for example).</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-n</emphasis></term>
+        <listitem>
+          <para>Displays a list of the tapes necessary to perform the requested restore,
+          without actually performing the operation.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-localauth</emphasis></term>
+        <listitem>
+          <para>Constructs a server ticket using a key from the local
+          <replaceable>/usr/afs/etc/KeyFile</replaceable> file. The <emphasis role="bold">backup</emphasis> command interpreter presents
+          it to the Backup Server, Volume Server and VL Server during mutual
+          authentication. Do not combine this flag with the <emphasis role="bold">-cell</emphasis> argument. For
+          more details, see <link linkend="backup8">backup(8)</link>.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-cell</emphasis> &lt;<emphasis>cell name</emphasis>&gt;</term>
+        <listitem>
+          <para>Names the cell in which to run the command. Do not combine this argument
+          with the <emphasis role="bold">-localauth</emphasis> flag. For more details, see <link linkend="backup8">backup(8)</link>.</para>
+
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><emphasis role="bold">-help</emphasis></term>
+        <listitem>
+          <para>Prints the online help for this command. All other valid options are
+          ignored.</para>
+
+        </listitem>
+      </varlistentry>
+    </variablelist>
+  </refsect1>
+  <refsect1>
+    <title>Output</title>
+    <para>If a tape error occurs during the restore operation, the Tape Coordinator
+    displays the following messages:</para>
+
+<programlisting>
+   Restore operation on volume I&amp;lt;name&amp;gt; failed due to tape error
+   Do you want to continue (y/n)?
+
+</programlisting>
+      <para>where <emphasis>name</emphasis> is the name of the volume that was being restored when the
+      tape error occurred. Enter the value <emphasis role="bold">y</emphasis> to continue the operation
+      without restoring the indicated volume or the value <computeroutput>n</computeroutput> to terminate the
+      operation. In the latter case, the operator can then attempt to determine
+      the cause of the tape error.</para>
+
+      <para>If the issuer includes the <emphasis role="bold">-n</emphasis> flag with the command, the following
+      string appears at the head of the list of the tapes necessary to perform
+      the restore operation:</para>
+
+<programlisting>
+   Tapes needed:
+
+</programlisting>
+      </refsect1>
+      <refsect1>
+        <title>Examples</title>
+        <para>The following command restores the volumes for which the VLDB lists a
+        read/write site on the <replaceable>/vicepd</replaceable> partition of the machine
+        <computeroutput>fs5.abc.com</computeroutput>. The Tape Coordinator associated with port offset 3
+        performs the operation.</para>
+
+<programlisting>
+   % backup diskrestore -server fs5.abc.com -partition /vicepd -portoffset 3
+
+</programlisting>
+          <para>The following command restores the volumes for which the VLDB lists a
+          read/write site on the <replaceable>/vicepb</replaceable> partition of the machine <computeroutput>fs1.abc.com</computeroutput>
+          to a new site: the <replaceable>/vicepa</replaceable> partition on the machine <computeroutput>fs3.abc.com</computeroutput>. The
+          Tape Coordinator associated with port offset 0 performs the
+          operation. (The command appears here on two lines only for legibility.)</para>
+
+<programlisting>
+   % backup diskrestore  -server fs1.abc.com -partition /vicepb   \
+                         -newserver fs3.abc.com -newpartition /vicepa
+
+</programlisting>
+            <para>The following command lists the tapes required to restore the volumes for
+            which the VLDB lists a read/write site on the <replaceable>/vicepm</replaceable> partition of the
+            machine <computeroutput>fs4.abc.com</computeroutput>:</para>
+
+<programlisting>
+   % backup diskrestore -server fs4.abc.com -partition /vicepm -n
+   Tapes needed:
+   user.sunday1.1
+   user.sunday1.2
+   user.monday1.1
+   user.tuesday1.1
+   user.wednesday1.1
+
+</programlisting>
+            </refsect1>
+            <refsect1>
+              <title>Privilege Required</title>
+              <para>The issuer must be listed in the <replaceable>/usr/afs/etc/UserList</replaceable> file on every
+              machine where the Backup Server or Volume Location (VL) Server is running,
+              and on every file server machine that houses an affected volume. If the
+              <emphasis role="bold">-localauth</emphasis> flag is included, the issuer must instead be logged on to a
+              server machine as the local superuser <computeroutput>root</computeroutput>.</para>
+
+            </refsect1>
+            <refsect1>
+              <title>See Also</title>
+              <para><link linkend="butc5">butc(5)</link>,
+              <link linkend="backup8">backup(8)</link>,
+              <link linkend="backup_dump8">backup_dump(8)</link>,
+              <link linkend="backup_volrestore8">backup_volrestore(8)</link>,
+              <link linkend="backup_volsetrestore8">backup_volsetrestore(8)</link>,
+              <link linkend="butc8">butc(8)</link>,
+              <link linkend="vos_backup1">vos_backup(1)</link>,
+              <link linkend="vos_examine1">vos_examine(1)</link>,
+              <link linkend="vos_listvol1">vos_listvol(1)</link>,
+              <link linkend="vos_release1">vos_release(1)</link></para>
+
+            </refsect1>
+            <refsect1>
+              <title>Copyright</title>
+              <para>IBM Corporation 2000. &lt;http://www.ibm.com/&gt; All Rights Reserved.</para>
+
+              <para>This documentation is covered by the IBM Public License Version 1.0.  It was
+              converted from HTML to POD by software written by Chas Williams and Russ
+              Allbery, based on work by Alf Wachsmann and Elizabeth Cassell.</para>
+
+            </refsect1>
+          </refentry>