.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "BACKUP_DISKRESTORE 8" .TH BACKUP_DISKRESTORE 8 "2023-12-24" "OpenAFS" "AFS Command Reference" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" backup_diskrestore \- Restores the entire contents of a partition .SH "SYNOPSIS" .IX Header "SYNOPSIS" \&\fBbackup diskrestore\fR \fB\-server\fR\ <\fImachine\ to\ restore\fR> \fB\-partition\fR\ <\fIpartition\ to\ restore\fR> [\fB\-portoffset\fR\ <\fI\s-1TC\s0\ port\ offset\fR>+] [\fB\-newserver\fR\ <\fIdestination\ machine\fR>] [\fB\-newpartition\fR\ <\fIdestination\ partition\fR>] [\fB\-extension\fR\ <\fInew\ volume\ name\ extension\fR>] [\fB\-dryrun\fR | \fB\-n\fR] [\fB\-localauth\fR] [\fB\-cell\fR\ <\fIcell\ name\fR>] [\fB\-help\fR] .PP \&\fBbackup di\fR \fB\-s\fR\ <\fImachine\ to\ restore\fR> \fB\-pa\fR\ <\fIpartition\ to\ restore\fR> [\fB\-po\fR\ <\fI\s-1TC\s0\ port\ offset\fR>+] [\fB\-news\fR\ <\fIdestination\ machine\fR>] [\fB\-newp\fR\ <\fIdestination\ partition\fR>] [\fB\-e\fR\ <\fInew\ volume\ name\ extension\fR>] [\fB\-dryrun\fR | \fB\-n\fR] [\fB\-l\fR] [\fB\-c\fR\ <\fIcell\ name\fR>] [\fB\-h\fR] .SH "DESCRIPTION" .IX Header "DESCRIPTION" The \fBbackup diskrestore\fR command restores all of the volumes for which the Volume Location Database (\s-1VLDB\s0) lists a read/write site on the partition specified with the \fB\-server\fR and \fB\-partition\fR 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 \fBvos release\fR and \fBvos backup\fR commands, respectively, after restoring the read/write version.) .PP If restoring only selected volumes to a single site, it is usually more efficient to use the \fBbackup volrestore\fR command. To restore multiple volumes to many different sites, use the \fBbackup volsetrestore\fR command. .PP (If the \f(CW\*(C`FILE YES\*(C'\fR instruction appears in the \&\fI/var/lib/openafs/backup/CFG_\fIdevice_name\fI\fR 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 \fI/var/lib/openafs/backup/tapeconfig\fR 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.) .PP 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 \f(CW\*(C`Creation\*(C'\fR field of the output from the \fBvos examine\fR and \fBvos listvol\fR commands). .PP If all of the full and incremental dumps of all relevant volumes were not written on compatible tape devices, use the \fB\-portoffset\fR 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 \fBbackup volrestore\fR command to restore individual volumes, or the \fBbackup volsetrestore\fR command after defining groups of volumes that were dumped to compatible tape types. For further discussion, see the \fIOpenAFS Administration Guide\fR. .PP 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 \s-1VLDB.\s0 .IP "\(bu" 4 To restore to a different partition on the same file server machine, provide the \fB\-newpartition\fR argument. .IP "\(bu" 4 To restore to the partition with the same name on a different file server machine, provide the \fB\-newserver\fR argument. .IP "\(bu" 4 To restore to a completely different site, combine the \fB\-newserver\fR and \&\fB\-newpartition\fR arguments. .PP 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 \fB\-extension\fR argument. The Backup System creates the new volume at the site designated by the \fB\-newserver\fR and \fB\-newpartition\fR arguments if they are used or the \fB\-server\fR and \fB\-partition\fR arguments otherwise. It derives the volume name by adding the extension to the read/write base name listed in the \s-1VLDB,\s0 and creates a new \s-1VLDB\s0 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. .PP To print out a list of the tapes containing the needed dumps, without actually performing the restore operation, include the \fB\-dryrun\fR flag along with the other options to be used on the actual command. .PP The Tape Coordinator's default response to this command is to access the first tape it needs by invoking the \f(CW\*(C`MOUNT\*(C'\fR instruction in the local \&\fI\s-1CFG_\s0\fIdevice_name\fI\fR file, or by prompting the backup operator to insert the tape if there is no \f(CW\*(C`MOUNT\*(C'\fR instruction. However, if the \f(CW\*(C`AUTOQUERY NO\*(C'\fR instruction appears in the \fI\s-1CFG_\s0\fIdevice_name\fI\fR file, or if the issuer of the \fBbutc\fR command included the \fB\-noautoquery\fR 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 \f(CW\*(C`MOUNT\*(C'\fR instruction or prompts the operator. It also invokes the \f(CW\*(C`MOUNT\*(C'\fR instruction or prompts for any additional tapes needed to complete the restore operation; the backup operator must arrange to provide them. .SH "CAUTIONS" .IX Header "CAUTIONS" If issuing this command to recover data after a disk crash or other damage, be sure not to issue the \fBvos syncserv\fR command first. Doing so destroys the \s-1VLDB\s0 record of the volumes that resided on the partition. .SH "OPTIONS" .IX Header "OPTIONS" .IP "\fB\-server\fR <\fImachine to restore\fR>" 4 .IX Item "-server " Names the file server machine that the \s-1VLDB\s0 lists as the site of the volumes that need to be restored. .IP "\fB\-partition\fR <\fIpartition to restore\fR>" 4 .IX Item "-partition " Names the partition that the \s-1VLDB\s0 lists as the site of the volumes that need to be restored. .IP "\fB\-portoffset\fR <\fI\s-1TC\s0 port offset\fR>+" 4 .IX Item "-portoffset +" 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. .Sp Provide this argument unless the default value of 0 (zero) is appropriate for all dumps. If \f(CW0\fR is just one of the values in the list, provide it explicitly in the appropriate order. .IP "\fB\-newserver\fR <\fIdestination machine\fR>" 4 .IX Item "-newserver " 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 \fB\-server\fR argument. .IP "\fB\-newpartition\fR <\fIdestination partition\fR>" 4 .IX Item "-newpartition " 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 \fB\-partition\fR argument. .IP "\fB\-extension\fR <\fInew volume name extension\fR>" 4 .IX Item "-extension " 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 \s-1VLDB,\s0 and creates a new \s-1VLDB\s0 volume entry. The Backup System preserves the contents of the volumes on the partition, if any still exist. Any string other than \&\f(CW\*(C`.readonly\*(C'\fR or \f(CW\*(C`.backup\*(C'\fR 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 \f(CW\*(C`.rst\*(C'\fR, for example). .IP "\fB\-dryrun\fR | \fB\-n\fR" 4 .IX Item "-dryrun | -n" Displays a list of the tapes necessary to perform the requested restore, without actually performing the operation. .IP "\fB\-localauth\fR" 4 .IX Item "-localauth" Constructs a server ticket using a key from the local \&\fI/etc/openafs/server/KeyFile\fR file. The \fBbackup\fR command interpreter presents it to the Backup Server, Volume Server and \s-1VL\s0 Server during mutual authentication. Do not combine this flag with the \fB\-cell\fR argument. For more details, see \fBbackup\fR\|(8). .IP "\fB\-cell\fR <\fIcell name\fR>" 4 .IX Item "-cell " Names the cell in which to run the command. Do not combine this argument with the \fB\-localauth\fR flag. For more details, see \fBbackup\fR\|(8). .IP "\fB\-help\fR" 4 .IX Item "-help" Prints the online help for this command. All other valid options are ignored. .SH "OUTPUT" .IX Header "OUTPUT" If a tape error occurs during the restore operation, the Tape Coordinator displays the following messages: .PP .Vb 2 \& Restore operation on volume I failed due to tape error \& Do you want to continue (y/n)? .Ve .PP where \fIname\fR is the name of the volume that was being restored when the tape error occurred. Enter the value \fBy\fR to continue the operation without restoring the indicated volume or the value \f(CW\*(C`n\*(C'\fR to terminate the operation. In the latter case, the operator can then attempt to determine the cause of the tape error. .PP If the issuer includes the \fB\-dryrun\fR flag with the command, the following string appears at the head of the list of the tapes necessary to perform the restore operation: .PP .Vb 1 \& Tapes needed: .Ve .SH "EXAMPLES" .IX Header "EXAMPLES" The following command restores the volumes for which the \s-1VLDB\s0 lists a read/write site on the \fI/vicepd\fR partition of the machine \&\f(CW\*(C`fs5.example.com\*(C'\fR. The Tape Coordinator associated with port offset 3 performs the operation. .PP .Vb 2 \& % backup diskrestore \-server fs5.example.com \e \& \-partition /vicepd \-portoffset 3 .Ve .PP The following command restores the volumes for which the \s-1VLDB\s0 lists a read/write site on the \fI/vicepb\fR partition of the machine \f(CW\*(C`fs1.example.com\*(C'\fR to a new site: the \fI/vicepa\fR partition on the machine \f(CW\*(C`fs3.example.com\*(C'\fR. The Tape Coordinator associated with port offset 0 performs the operation. (The command appears here on two lines only for legibility.) .PP .Vb 2 \& % backup diskrestore \-server fs1.example.com \-partition /vicepb \e \& \-newserver fs3.example.com \-newpartition /vicepa .Ve .PP The following command lists the tapes required to restore the volumes for which the \s-1VLDB\s0 lists a read/write site on the \fI/vicepm\fR partition of the machine \f(CW\*(C`fs4.example.com\*(C'\fR: .PP .Vb 7 \& % backup diskrestore \-server fs4.example.com \-partition /vicepm \-dryrun \& Tapes needed: \& user.sunday1.1 \& user.sunday1.2 \& user.monday1.1 \& user.tuesday1.1 \& user.wednesday1.1 .Ve .SH "PRIVILEGE REQUIRED" .IX Header "PRIVILEGE REQUIRED" The issuer must be listed in the \fI/etc/openafs/server/UserList\fR file on every machine where the Backup Server or Volume Location (\s-1VL\s0) Server is running, and on every file server machine that houses an affected volume. If the \&\fB\-localauth\fR flag is included, the issuer must instead be logged on to a server machine as the local superuser \f(CW\*(C`root\*(C'\fR. .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fBbutc\fR\|(5), \&\fBbackup\fR\|(8), \&\fBbackup_dump\fR\|(8), \&\fBbackup_volrestore\fR\|(8), \&\fBbackup_volsetrestore\fR\|(8), \&\fBbutc\fR\|(8), \&\fBvos_backup\fR\|(1), \&\fBvos_examine\fR\|(1), \&\fBvos_listvol\fR\|(1), \&\fBvos_release\fR\|(1) .SH "COPYRIGHT" .IX Header "COPYRIGHT" \&\s-1IBM\s0 Corporation 2000. All Rights Reserved. .PP This documentation is covered by the \s-1IBM\s0 Public License Version 1.0. It was converted from \s-1HTML\s0 to \s-1POD\s0 by software written by Chas Williams and Russ Allbery, based on work by Alf Wachsmann and Elizabeth Cassell.