<tt>tar</tt>: Tape Archive



next up previous contents
Next: dd: Image Copy Up: Utilities Previous: tctl: Tape Control

tar: Tape Archive

tar is a utility that packages a list of files (and/or directories) into a specific tarfile, which typically ends in .tar.

tar is invoked by

where device... is the name of the tape device or tar file, and filename... may be files and/or directories combined to produce the tar file. One of c, t, or x must be used.
-c
(create): creates a new tarfile.
-t
(table): lists the files on the tarfile.
-x
(extract): extracts the files from the tarfile.

The three other options are:

-v
(verbose): the size and name of each file put onto or extracted from the tarfile is displayed.
-o
(ownership): on the extraction of files, do NOT extract the original ownership of the files and directories. This avoids the message permission denied when reading tar_files. Available only on SGI machines, it is the default on SUNs.
-f
(device): uses the next argument as the name of the tarfile. It is normally in the form /dev/tape where tape is the name of the device the file is written onto/extracted from.

For example, to write the files utilities.tex and course.tex onto a 1/4-inch cartridge tape (device /dev/tape) on a Silicon Graphics workstation:

tar -cvf /dev/tape utilities.tex course.tex

To read the files back onto another SGI:

tar -xvf /dev/tape

To list the contents of the file:

tar -tvf /dev/tape

NOTES:



next up previous contents
Next: dd: Image Copy Up: Utilities Previous: tctl: Tape Control



Super-User
Fri Feb 17 15:55:40 EST 1995