Click on any of the 687 commands below to get a description and list of available options. All links in the command summaries point to the online version of the book on Safari Bookshelf.
System administration command. Restore backed up files from a dump archive. Execute this command with one of the following flags.
Flags
-C
Compare files on disk to files in the backup and print report.
-i
Restore files interactively. This will open a shell-like interface that accepts the following commands.
add [name]
Add the current working directory, or the specified file or directory name to the list of files to extract.
cddirectory
Change the current working directory.
delete [name]
Remove the current working directory or the specified file or directory name from the list of files to extract.
extract
Extract selected files. This will prompt for the volume on which the files to be extracted can be found. Once the files are extracted, the system will prompt if you want to change the ownership and mode of the current directory (the one to which you extracted the files) to match the settings on the dump's original base directory.
help
Print a command summary.
ls [name]
Like the shell command, list files in the current working directory, or the specified file or directory name. A * before a name indicates items marked for extraction. In verbose mode, the listing will include each item's inode.
pwd
Like the shell command, print the working directory.
quit
Exit the command.
setmodes
Set ownership and mode of the directory to which you extract the files to match the settings on the dump's original base directory.
quit
Exit the command.
verbose
Verbose mode. Print inodes along with file and directory names when using ls.
-P filename
Create a Quick File Access file suitable for use with the -Q option.
-R
Prompt for the tape volume to fully restore.
-r
Fully restore the backup to a clean, newly created ext2 filesystem. Execute this command in the root directory of the new filesystem.
-t
Print files if they exist in the archive or an error if they do not. If no files are specified, list all files in the archive.
-x
Recursively extract files if they exist in the archive. Restore owner, modification times, and modes. If no files are specified, restore the entire backup.
Options
-a
Read all volumes to find the files to extract, beginning with volume 1. This will skip any volume prompts.
-A file
Read the table of contents from the specified archive file.
-bblocksize
Specify the block size in kilobytes used for a block in the archive. Restore can usually determine this when reading the dump media.
-c
Read dumps made prior to Version 4.4.
-d
Print debugging information.
-Dfilesystem
When using the -C flag, compare the dump to files on the specified filesystem.
-ffile
Read the backup from the specified file: a device file, an ordinary file, or - to read from standard input. Use host:file or user@host:file to read from a networked host using either the rmt program or the program specified by the RMT environment variable.
-Fscript
Run the specified script at the beginning of each volume. restore will pass the current device and volume number to the script. The script should return 0 to continue, 1 to prompt for a new tape, or any other exit value to abort the restore. The script will run with the process's real user and group ID.
-h
Do not recursively restore directory. Only restore the specified directory.
-k
Use Kerberos authentication when connecting to a remote server.
-l
Treat file as a regular file instead of a tape device. Use this option when restoring from remote compressed files.
-Ln
Used with the -C flag. Abort the comparison after encountering n errors.
-m
Expect filenames to be given as inodes.
-M
Restore from a multivolume backup. Treat any filename provided with -f as a prefix.
-N
Perform all actions indicated by other flags and options, but don't write anything to the disk.
-o
Automatically set ownership and mode of the current directory to match the original base directory of the dump.
-Qfile
Read tape positions from the specified Quick File Access mode file.
-Sn
Read from volume n of a multifile backup.
-u
Unlink (remove) any existing files before writing a file with the same name.
-v
Verbose mode. Print information about files being restored.
-V
Enable multivolume mode for devices other than tapes.
-Xfile
Read list of files and directories to extract from the specified file. Use - to retrieve list of files from standard input.
-y
Attempt to skip over errors without prompting for operator input.