|
|
1.1 ! root 1: .\" Copyright (c) 1985 The Regents of the University of California. ! 2: .\" All rights reserved. ! 3: .\" ! 4: .\" Redistribution and use in source and binary forms are permitted provided ! 5: .\" that: (1) source distributions retain this entire copyright notice and ! 6: .\" comment, and (2) distributions including binaries display the following ! 7: .\" acknowledgement: ``This product includes software developed by the ! 8: .\" University of California, Berkeley and its contributors'' in the ! 9: .\" documentation or other materials provided with the distribution and in ! 10: .\" all advertising materials mentioning features or use of this software. ! 11: .\" Neither the name of the University nor the names of its contributors may ! 12: .\" be used to endorse or promote products derived from this software without ! 13: .\" specific prior written permission. ! 14: .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED ! 15: .\" WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF ! 16: .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ! 17: .\" ! 18: .\" @(#)restore.8 6.8 (Berkeley) 6/24/90 ! 19: .\" ! 20: .TH RESTORE 8 "June 24, 1990" ! 21: .UC 4 ! 22: .SH NAME ! 23: restore \- incremental file system restore ! 24: .SH SYNOPSIS ! 25: .B restore ! 26: key [ name ... ] ! 27: .SH DESCRIPTION ! 28: .PP ! 29: .I Restore ! 30: reads tapes dumped with the ! 31: .IR dump (8) ! 32: command. ! 33: Its actions are controlled by the ! 34: .I key ! 35: argument. ! 36: The ! 37: .I key ! 38: is a string of characters containing ! 39: at most one function letter and possibly ! 40: one or more function modifiers. ! 41: Other arguments to the command are file or directory ! 42: names specifying the files that are to be restored. ! 43: Unless the ! 44: .B h ! 45: key is specified (see below), ! 46: the appearance of a directory name refers to ! 47: the files and (recursively) subdirectories of that directory. ! 48: .PP ! 49: The function portion of ! 50: the key is specified by one of the following letters: ! 51: .TP 5n ! 52: .B r ! 53: The tape ! 54: is read and loaded into the current directory. ! 55: This should not be done lightly; the ! 56: .B r ! 57: key should only be used to restore ! 58: a complete dump tape onto a clear file system ! 59: or to restore an incremental dump tape after a full level zero restore. ! 60: Thus ! 61: .IP "" 5n ! 62: newfs /dev/rrp0g eagle ! 63: .br ! 64: mount /dev/rp0g /mnt ! 65: .br ! 66: cd /mnt ! 67: .br ! 68: restore r ! 69: .IP "" 5n ! 70: is a typical sequence to restore a complete dump. ! 71: Another ! 72: .I restore ! 73: can be done to get an incremental dump ! 74: in on top of this. ! 75: Note that ! 76: .I restore ! 77: leaves a file ! 78: .I restoresymtable ! 79: in the root directory to pass information between incremental ! 80: restore passes. ! 81: This file should be removed when the last incremental tape has been ! 82: restored. ! 83: .br ! 84: A ! 85: .IR dump (8) ! 86: followed by a ! 87: .IR newfs (8) ! 88: and a ! 89: .I restore ! 90: is used to change the size of a file system. ! 91: .TP 5n ! 92: .B R ! 93: .I Restore ! 94: requests a particular tape of a multi volume set on which to restart ! 95: a full restore ! 96: (see the ! 97: .B r ! 98: key above). ! 99: This allows ! 100: .I restore ! 101: to be interrupted and then restarted. ! 102: .TP 5n ! 103: .B x ! 104: The named files are extracted from the tape. ! 105: If the named file matches a directory whose contents ! 106: had been written onto the tape, ! 107: and the ! 108: .B h ! 109: key is not specified, ! 110: the directory is recursively extracted. ! 111: The owner, modification time, ! 112: and mode are restored (if possible). ! 113: If no file argument is given, ! 114: then the root directory is extracted, ! 115: which results in the entire content of the ! 116: tape being extracted, ! 117: unless the ! 118: .B h ! 119: key has been specified. ! 120: .TP 5n ! 121: .B t ! 122: The names of the specified files are listed if they occur ! 123: on the tape. ! 124: If no file argument is given, ! 125: then the root directory is listed, ! 126: which results in the entire content of the ! 127: tape being listed, ! 128: unless the ! 129: .B h ! 130: key has been specified. ! 131: Note that the ! 132: .B t ! 133: key replaces the function of the old ! 134: .I dumpdir ! 135: program. ! 136: .TP 5n ! 137: .B i ! 138: This mode allows interactive restoration of files from a dump tape. ! 139: After reading in the directory information from the tape, ! 140: .I restore ! 141: provides a shell like interface that allows the user to move ! 142: around the directory tree selecting files to be extracted. ! 143: The available commands are given below; ! 144: for those commands that require an argument, ! 145: the default is the current directory. ! 146: .IP "" 10n ! 147: .ti -5n ! 148: .br ! 149: .B ls ! 150: [arg] \- ! 151: List the current or specified directory. ! 152: Entries that are directories are appended with a ``/''. ! 153: Entries that have been marked for extraction are prepended with a ``*''. ! 154: If the verbose key is set the inode number of each entry is also listed. ! 155: .ti -5n ! 156: .sp ! 157: .B cd ! 158: arg \- ! 159: Change the current working directory to the specified argument. ! 160: .ti -5n ! 161: .sp ! 162: .B pwd ! 163: \- ! 164: Print the full pathname of the current working directory. ! 165: .ti -5n ! 166: .sp ! 167: .B add ! 168: [arg] \- ! 169: The current directory or specified argument is added to the list of ! 170: files to be extracted. ! 171: If a directory is specified, then it and all its descendents are ! 172: added to the extraction list ! 173: (unless the ! 174: .B h ! 175: key is specified on the command line). ! 176: Files that are on the extraction list are prepended with a ``*'' ! 177: when they are listed by ! 178: .BR ls . ! 179: .ti -5n ! 180: .sp ! 181: .B delete ! 182: [arg] \- ! 183: The current directory or specified argument is deleted from the list of ! 184: files to be extracted. ! 185: If a directory is specified, then it and all its descendents are ! 186: deleted from the extraction list ! 187: (unless the ! 188: .B h ! 189: key is specified on the command line). ! 190: The most expedient way to extract most of the files from a directory ! 191: is to add the directory to the extraction list and then delete ! 192: those files that are not needed. ! 193: .ti -5n ! 194: .sp ! 195: .B extract ! 196: \- ! 197: All the files that are on the extraction list are extracted ! 198: from the dump tape. ! 199: .I Restore ! 200: will ask which volume the user wishes to mount. ! 201: The fastest way to extract a few files is to ! 202: start with the last volume, and work towards the first volume. ! 203: .ti -5n ! 204: .sp ! 205: .B setmodes ! 206: \- ! 207: All the directories that have been added to the extraction list ! 208: have their owner, modes, and times set; ! 209: nothing is extracted from the tape. ! 210: This is useful for cleaning up after a restore has been prematurely aborted. ! 211: .ti -5n ! 212: .sp ! 213: .B verbose ! 214: \- ! 215: The sense of the ! 216: .B v ! 217: key is toggled. ! 218: When set, the verbose key causes the ! 219: .B ls ! 220: command to list the inode numbers of all entries. ! 221: It also causes ! 222: .I restore ! 223: to print out information about each file as it is extracted. ! 224: .ti -5n ! 225: .sp ! 226: .B help ! 227: \- ! 228: List a summary of the available commands. ! 229: .ti -5n ! 230: .sp ! 231: .B quit ! 232: \- ! 233: Restore immediately exits, ! 234: even if the extraction list is not empty. ! 235: .sp ! 236: .PP ! 237: The following characters may be used in addition to the letter ! 238: that selects the function desired. ! 239: .TP 5n ! 240: .B b ! 241: The next argument to ! 242: .I restore ! 243: is used as the block size of the tape (in kilobytes). ! 244: If the \fB-b\fP option is not specified, ! 245: .I restore ! 246: tries to determine the tape block size dynamically. ! 247: .TP 5n ! 248: .B f ! 249: The next argument to ! 250: .I restore ! 251: is used as the name of the archive instead ! 252: of /dev/rmt?. ! 253: If the name of the file is ``\-'', ! 254: .I restore ! 255: reads from standard input. ! 256: Thus, ! 257: .IR dump (8) ! 258: and ! 259: .I restore ! 260: can be used in a pipeline to dump and restore a file system ! 261: with the command ! 262: .IP "" 5n ! 263: dump 0f - /usr | (cd /mnt; restore xf -) ! 264: .TP 5n ! 265: .B v ! 266: Normally ! 267: .I restore ! 268: does its work silently. ! 269: The ! 270: .B v ! 271: (verbose) ! 272: key causes it to type the name of each file it treats ! 273: preceded by its file type. ! 274: .TP 5n ! 275: .B y ! 276: .I Restore ! 277: will not ask whether it should abort the restore if gets a tape error. ! 278: It will always try to skip over the bad tape block(s) and continue as ! 279: best it can. ! 280: .TP 5n ! 281: .B m ! 282: .I Restore ! 283: will extract by inode numbers rather than by file name. ! 284: This is useful if only a few files are being extracted, ! 285: and one wants to avoid regenerating the complete pathname ! 286: to the file. ! 287: .TP 5n ! 288: .B h ! 289: .I Restore ! 290: extracts the actual directory, ! 291: rather than the files that it references. ! 292: This prevents hierarchical restoration of complete subtrees ! 293: from the tape. ! 294: .TP 5n ! 295: .B s ! 296: The next argument to ! 297: .I restore ! 298: is a number which ! 299: selects the file on a multi-file dump tape. File numbering ! 300: starts at 1. ! 301: .SH DIAGNOSTICS ! 302: Complaints about bad key characters. ! 303: .PP ! 304: Complaints if it gets a read error. ! 305: If ! 306: .B y ! 307: has been specified, or the user responds ``y'', ! 308: .I restore ! 309: will attempt to continue the restore. ! 310: .PP ! 311: If the dump extends over more than one tape, ! 312: .I restore ! 313: will ask the user to change tapes. ! 314: If the ! 315: .B x ! 316: or ! 317: .B i ! 318: key has been specified, ! 319: .I restore ! 320: will also ask which volume the user wishes to mount. ! 321: The fastest way to extract a few files is to ! 322: start with the last volume, and work towards the first volume. ! 323: .PP ! 324: There are numerous consistency checks that can be listed by ! 325: .IR restore . ! 326: Most checks are self-explanatory or can ``never happen''. ! 327: Common errors are given below. ! 328: .IP "Converting to new file system format." 5n ! 329: .br ! 330: A dump tape created from the old file system has been loaded. ! 331: It is automatically converted to the new file system format. ! 332: .IP "<filename>: not found on tape" 5n ! 333: .br ! 334: The specified file name was listed in the tape directory, ! 335: but was not found on the tape. ! 336: This is caused by tape read errors while looking for the file, ! 337: and from using a dump tape created on an active file system. ! 338: .IP "expected next file <inumber>, got <inumber>" 5n ! 339: .br ! 340: A file that was not listed in the directory showed up. ! 341: This can occur when using a dump tape created on an active file system. ! 342: .IP "Incremental tape too low" 5n ! 343: .br ! 344: When doing incremental restore, ! 345: a tape that was written before the previous incremental tape, ! 346: or that has too low an incremental level has been loaded. ! 347: .IP "Incremental tape too high" 5n ! 348: .br ! 349: When doing incremental restore, ! 350: a tape that does not begin its coverage where the previous incremental ! 351: tape left off, ! 352: or that has too high an incremental level has been loaded. ! 353: .IP "Tape read error while restoring <filename>" 5n ! 354: .ti -5n ! 355: .br ! 356: Tape read error while skipping over inode <inumber> ! 357: .ti -5n ! 358: .br ! 359: Tape read error while trying to resynchronize ! 360: .br ! 361: A tape read error has occurred. ! 362: If a file name is specified, ! 363: then its contents are probably partially wrong. ! 364: If an inode is being skipped or the tape is trying to resynchronize, ! 365: then no extracted files have been corrupted, ! 366: though files may not be found on the tape. ! 367: .IP "resync restore, skipped <num> blocks" 5n ! 368: .br ! 369: After a tape read error, ! 370: .I restore ! 371: may have to resynchronize itself. ! 372: This message lists the number of blocks that were skipped over. ! 373: .SH FILES ! 374: /dev/rmt? the default tape drive ! 375: .br ! 376: /tmp/rstdir* file containing directories on the tape. ! 377: .br ! 378: /tmp/rstmode* owner, mode, and time stamps for directories. ! 379: .br ! 380: \&./restoresymtable information passed between incremental restores. ! 381: .SH SEE ALSO ! 382: rrestore(8C) dump(8), newfs(8), mount(8), mkfs(8) ! 383: .SH BUGS ! 384: .I Restore ! 385: can get confused when doing incremental restores from ! 386: dump tapes that were made on active file systems. ! 387: .PP ! 388: A level zero dump must be done after a full restore. ! 389: Because restore runs in user code, ! 390: it has no control over inode allocation; ! 391: thus a full restore must be done to get a new set of directories ! 392: reflecting the new inode numbering, ! 393: even though the contents of the files is unchanged.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.