HP DDS/DAT tape drives UNIX, Linux and OpenVMS configuration guide (DW049-90930, May 2010)

2. Write a sample file to tape, using 'tar':
% cd /
% tar cvf <archive name> <file>
The options to tar have the following meanings:
Create a new archive (backup file) on the device.
c
Operate in verbose mode.
v
Specify the archive name explicitly.
f
The arguments follow the cvf options in the command line. The arguments are as follows:
The name of the archive name to be created.
Example: /dev/st0
<archive name>
The name of the file to archive, prefixed with './' .
Example: ./boot/vmlinuz
<file>
NOTE:
Make sure you prefix the file name with ‘.' when you back it up to tape. If you do not,
the restore operation in step 3 will overwrite the original copy on disk.
3. Read the file back from tape:
% cd /tmp
% tar xvf <archive name>
The x' option to tar here means extract from the archive.
Use the same value for the <archive name> argument as in step 2.
4. Compare the original with this retrieved file:
% cmp <original file> /tmp/<retrieved file>
This step compares the retrieved file and the original file byte by byte. If they are the same, there
should be no output, and this verifies that the installation is correct. The arguments are as follows:
The name of the original file, prefixed with /'.
Example: /boot/vmlinuz
<original file>
The name of the file retrieved from the archive.
Example: boot/vmlinuz
<retrieved file>
Example
Suppose you are verifying the installation of an HP DDS-format tape drive on an HP-UX 10.X system.
The procedure would be as follows:
Verifying the installation40