
Backing up and Restoring Files
# P0602484 Ver: 2.7 Page 135
!
Do not backup to a medium that contains useful files. The tar command
overwrites existing files.
How to ... Back Up with tar
1. To make a tape-based backup:
a. Label the tape.
b. Insert the tape into the drive.
2. Log in as root.
a. From any command line enter su.
b. Enter the root password (____________).
3. Move to the directory where the files are located (the source
directory). See see Working with Directories on page 122..
4. Enter the tar command.
• To backup to a tape, use the syntax tar cvf /dev/rmt/0
<sourcefiles>.
• To backup to the present working directory, use the syntax
tar cvf <archivefile.tar> <sourcefiles>. Use
cp to place the tar file in an alternate directory or drive.
Use a descriptive file name with the .tar extension for <archive-
file.tar> (for example, oldvocabs.tar). This command com-
bines and saves the source file(s) in the archive file
<archivefile.tar>.
Specify either individual files or entire directories to be backed up. Back-
ups can also be made to an alternate directory or internal drive. See the
Solaris system documentation or details about the tar and cp com-
mands.
Displaying the Contents of a tar Backup
Display the table of contents for each backup to ensure that it is readable and
complete.
How to ... Display the Contents of a tar Backup
1. To display a tape backup, insert the tape into the drive.
2. Log in as root.
a. From any command line enter su.
Comentarios a estos manuales