Go to the previous, next section.

Operation mode modifiers

(This message will disappear, once this node revised.)

Operation mode modifiers

-W
--verify
Attempt to verify the archive after writing.

This option causes tar to verify the archive after writing it. Each volume is checked after it is written, and any discrepancies are recorded on the standard error output.

Verification requires that the archive be on a back-space-able medium. This means pipes, some cartridge tape drives, and some other devices cannot be verified.

--remove-files
Remove files after adding them to the archive.

-k
--keep-old-files
Do not overwrite existing files from archive.

The `--keep-old-files' (`-k') option prevents tar from over-writing existing files with files with the same name from the archive.

The `--keep-old-files' (`-k') option is meaningless with `--list' (`-t').

-S
--sparse
Handle sparse files efficiently.

This option causes all files to be put in the archive to be tested for sparseness, and handled specially if they are. The `--sparse' (`-S') option is useful when many dbm files, for example, are being backed up. Using this option dramatically decreases the amount of space needed to store such a file.

In later versions, this option may be removed, and the testing and treatment of sparse files may be done automatically with any special GNU options. For now, it is an option needing to be specified on the command line with the creation or updating of an archive.

-O
--to-stdout
Extract files to standard output.

When this option is used, instead of creating the files specified, tar writes the contents of the files extracted to its standard output. This may be useful if you are only extracting the files in order to send them through a pipe.

This option is meaningless with `--list' (`-t').

--ignore-failed-read
Do not exit with non-zero on unreadable files.

FIXME: This section needs to be written

To come: using Unix file linking capability to recreate directory structures--linking files into one subdirectory and then tarring that directory.

to come: nice hairy example using absolute-names, newer, etc.

Piping one tar to another is an easy way to copy a directory's contents from one disk to another, while preserving the dates, modes, owners and link-structure of all the files therein.

cd sourcedirectory; tar cf - . | (cd targetdir; tar xf -)

or

FIXME: the following using standard input/output correct??
cd sourcedirectory; tar --create --file=- . | (cd targetdir; tar --extract --file=-)

Archive files can be used for transporting a group of files from one system to another: put all relevant files into an archive on one computer system, transfer the archive to another, and extract the contents there. The basic transfer medium might be magnetic tape, Internet FTP, or even electronic mail (though you must encode the archive with uuencode in order to transport it properly by mail). Both machines do not have to use the same operating system, as long as they both support the tar program.

FIXME: mention uuencode on a paragraph of its own

FIXME: end construction

Go to the previous, next section.