Blame doc/man/tar.5

Packit Service 1d0348
.TH TAR 5 "December 27, 2016" ""
Packit Service 1d0348
.SH NAME
Packit Service 1d0348
.ad l
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
\- format of tape archive files
Packit Service 1d0348
.SH DESCRIPTION
Packit Service 1d0348
.ad l
Packit Service 1d0348
The
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
archive format collects any number of files, directories, and other
Packit Service 1d0348
file system objects (symbolic links, device nodes, etc.) into a single
Packit Service 1d0348
stream of bytes.
Packit Service 1d0348
The format was originally designed to be used with
Packit Service 1d0348
tape drives that operate with fixed-size blocks, but is widely used as
Packit Service 1d0348
a general packaging mechanism.
Packit Service 1d0348
.SS General Format
Packit Service 1d0348
A
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
archive consists of a series of 512-byte records.
Packit Service 1d0348
Each file system object requires a header record which stores basic metadata
Packit Service 1d0348
(pathname, owner, permissions, etc.) and zero or more records containing any
Packit Service 1d0348
file data.
Packit Service 1d0348
The end of the archive is indicated by two records consisting
Packit Service 1d0348
entirely of zero bytes.
Packit Service 1d0348
.PP
Packit Service 1d0348
For compatibility with tape drives that use fixed block sizes,
Packit Service 1d0348
programs that read or write tar files always read or write a fixed
Packit Service 1d0348
number of records with each I/O operation.
Packit Service 1d0348
These
Packit Service 1d0348
``blocks''
Packit Service 1d0348
are always a multiple of the record size.
Packit Service 1d0348
The maximum block size supported by early
Packit Service 1d0348
implementations was 10240 bytes or 20 records.
Packit Service 1d0348
This is still the default for most implementations
Packit Service 1d0348
although block sizes of 1MiB (2048 records) or larger are
Packit Service 1d0348
commonly used with modern high-speed tape drives.
Packit Service 1d0348
(Note: the terms
Packit Service 1d0348
``block''
Packit Service 1d0348
and
Packit Service 1d0348
``record''
Packit Service 1d0348
here are not entirely standard; this document follows the
Packit Service 1d0348
convention established by John Gilmore in documenting
Packit Service 1d0348
\fB\%pdtar\fP.)
Packit Service 1d0348
.SS Old-Style Archive Format
Packit Service 1d0348
The original tar archive format has been extended many times to
Packit Service 1d0348
include additional information that various implementors found
Packit Service 1d0348
necessary.
Packit Service 1d0348
This section describes the variant implemented by the tar command
Packit Service 1d0348
included in
Packit Service 1d0348
At v7,
Packit Service 1d0348
which seems to be the earliest widely-used version of the tar program.
Packit Service 1d0348
.PP
Packit Service 1d0348
The header record for an old-style
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
archive consists of the following:
Packit Service 1d0348
.RS 4
Packit Service 1d0348
.nf
Packit Service 1d0348
struct header_old_tar {
Packit Service 1d0348
	char name[100];
Packit Service 1d0348
	char mode[8];
Packit Service 1d0348
	char uid[8];
Packit Service 1d0348
	char gid[8];
Packit Service 1d0348
	char size[12];
Packit Service 1d0348
	char mtime[12];
Packit Service 1d0348
	char checksum[8];
Packit Service 1d0348
	char linkflag[1];
Packit Service 1d0348
	char linkname[100];
Packit Service 1d0348
	char pad[255];
Packit Service 1d0348
};
Packit Service 1d0348
.RE
Packit Service 1d0348
All unused bytes in the header record are filled with nulls.
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIname\fP
Packit Service 1d0348
Pathname, stored as a null-terminated string.
Packit Service 1d0348
Early tar implementations only stored regular files (including
Packit Service 1d0348
hardlinks to those files).
Packit Service 1d0348
One common early convention used a trailing "/" character to indicate
Packit Service 1d0348
a directory name, allowing directory permissions and owner information
Packit Service 1d0348
to be archived and restored.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fImode\fP
Packit Service 1d0348
File mode, stored as an octal number in ASCII.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIuid\fP, \fIgid\fP
Packit Service 1d0348
User id and group id of owner, as octal numbers in ASCII.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIsize\fP
Packit Service 1d0348
Size of file, as octal number in ASCII.
Packit Service 1d0348
For regular files only, this indicates the amount of data
Packit Service 1d0348
that follows the header.
Packit Service 1d0348
In particular, this field was ignored by early tar implementations
Packit Service 1d0348
when extracting hardlinks.
Packit Service 1d0348
Modern writers should always store a zero length for hardlink entries.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fImtime\fP
Packit Service 1d0348
Modification time of file, as an octal number in ASCII.
Packit Service 1d0348
This indicates the number of seconds since the start of the epoch,
Packit Service 1d0348
00:00:00 UTC January 1, 1970.
Packit Service 1d0348
Note that negative values should be avoided
Packit Service 1d0348
here, as they are handled inconsistently.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIchecksum\fP
Packit Service 1d0348
Header checksum, stored as an octal number in ASCII.
Packit Service 1d0348
To compute the checksum, set the checksum field to all spaces,
Packit Service 1d0348
then sum all bytes in the header using unsigned arithmetic.
Packit Service 1d0348
This field should be stored as six octal digits followed by a null and a space
Packit Service 1d0348
character.
Packit Service 1d0348
Note that many early implementations of tar used signed arithmetic
Packit Service 1d0348
for the checksum field, which can cause interoperability problems
Packit Service 1d0348
when transferring archives between systems.
Packit Service 1d0348
Modern robust readers compute the checksum both ways and accept the
Packit Service 1d0348
header if either computation matches.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIlinkflag\fP, \fIlinkname\fP
Packit Service 1d0348
In order to preserve hardlinks and conserve tape, a file
Packit Service 1d0348
with multiple links is only written to the archive the first
Packit Service 1d0348
time it is encountered.
Packit Service 1d0348
The next time it is encountered, the
Packit Service 1d0348
\fIlinkflag\fP
Packit Service 1d0348
is set to an ASCII
Packit Service 1d0348
Sq 1
Packit Service 1d0348
and the
Packit Service 1d0348
\fIlinkname\fP
Packit Service 1d0348
field holds the first name under which this file appears.
Packit Service 1d0348
(Note that regular files have a null value in the
Packit Service 1d0348
\fIlinkflag\fP
Packit Service 1d0348
field.)
Packit Service 1d0348
.RE
Packit Service 1d0348
.PP
Packit Service 1d0348
Early tar implementations varied in how they terminated these fields.
Packit Service 1d0348
The tar command in
Packit Service 1d0348
At v7
Packit Service 1d0348
used the following conventions (this is also documented in early BSD manpages):
Packit Service 1d0348
the pathname must be null-terminated;
Packit Service 1d0348
the mode, uid, and gid fields must end in a space and a null byte;
Packit Service 1d0348
the size and mtime fields must end in a space;
Packit Service 1d0348
the checksum is terminated by a null and a space.
Packit Service 1d0348
Early implementations filled the numeric fields with leading spaces.
Packit Service 1d0348
This seems to have been common practice until the
Packit Service 1d0348
IEEE Std 1003.1-1988 (``POSIX.1'')
Packit Service 1d0348
standard was released.
Packit Service 1d0348
For best portability, modern implementations should fill the numeric
Packit Service 1d0348
fields with leading zeros.
Packit Service 1d0348
.SS Pre-POSIX Archives
Packit Service 1d0348
An early draft of
Packit Service 1d0348
IEEE Std 1003.1-1988 (``POSIX.1'')
Packit Service 1d0348
served as the basis for John Gilmore's
Packit Service 1d0348
\fB\%pdtar\fP
Packit Service 1d0348
program and many system implementations from the late 1980s
Packit Service 1d0348
and early 1990s.
Packit Service 1d0348
These archives generally follow the POSIX ustar
Packit Service 1d0348
format described below with the following variations:
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.IP \(bu
Packit Service 1d0348
The magic value consists of the five characters
Packit Service 1d0348
``ustar''
Packit Service 1d0348
followed by a space.
Packit Service 1d0348
The version field contains a space character followed by a null.
Packit Service 1d0348
.IP \(bu
Packit Service 1d0348
The numeric fields are generally filled with leading spaces
Packit Service 1d0348
(not leading zeros as recommended in the final standard).
Packit Service 1d0348
.IP \(bu
Packit Service 1d0348
The prefix field is often not used, limiting pathnames to
Packit Service 1d0348
the 100 characters of old-style archives.
Packit Service 1d0348
.RE
Packit Service 1d0348
.SS POSIX ustar Archives
Packit Service 1d0348
IEEE Std 1003.1-1988 (``POSIX.1'')
Packit Service 1d0348
defined a standard tar file format to be read and written
Packit Service 1d0348
by compliant implementations of
Packit Service 1d0348
\fBtar\fP(1).
Packit Service 1d0348
This format is often called the
Packit Service 1d0348
``ustar''
Packit Service 1d0348
format, after the magic value used
Packit Service 1d0348
in the header.
Packit Service 1d0348
(The name is an acronym for
Packit Service 1d0348
``Unix Standard TAR''.)
Packit Service 1d0348
It extends the historic format with new fields:
Packit Service 1d0348
.RS 4
Packit Service 1d0348
.nf
Packit Service 1d0348
struct header_posix_ustar {
Packit Service 1d0348
	char name[100];
Packit Service 1d0348
	char mode[8];
Packit Service 1d0348
	char uid[8];
Packit Service 1d0348
	char gid[8];
Packit Service 1d0348
	char size[12];
Packit Service 1d0348
	char mtime[12];
Packit Service 1d0348
	char checksum[8];
Packit Service 1d0348
	char typeflag[1];
Packit Service 1d0348
	char linkname[100];
Packit Service 1d0348
	char magic[6];
Packit Service 1d0348
	char version[2];
Packit Service 1d0348
	char uname[32];
Packit Service 1d0348
	char gname[32];
Packit Service 1d0348
	char devmajor[8];
Packit Service 1d0348
	char devminor[8];
Packit Service 1d0348
	char prefix[155];
Packit Service 1d0348
	char pad[12];
Packit Service 1d0348
};
Packit Service 1d0348
.RE
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
\fItypeflag\fP
Packit Service 1d0348
Type of entry.
Packit Service 1d0348
POSIX extended the earlier
Packit Service 1d0348
\fIlinkflag\fP
Packit Service 1d0348
field with several new type values:
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
``0''
Packit Service 1d0348
Regular file.
Packit Service 1d0348
NUL should be treated as a synonym, for compatibility purposes.
Packit Service 1d0348
.TP
Packit Service 1d0348
``1''
Packit Service 1d0348
Hard link.
Packit Service 1d0348
.TP
Packit Service 1d0348
``2''
Packit Service 1d0348
Symbolic link.
Packit Service 1d0348
.TP
Packit Service 1d0348
``3''
Packit Service 1d0348
Character device node.
Packit Service 1d0348
.TP
Packit Service 1d0348
``4''
Packit Service 1d0348
Block device node.
Packit Service 1d0348
.TP
Packit Service 1d0348
``5''
Packit Service 1d0348
Directory.
Packit Service 1d0348
.TP
Packit Service 1d0348
``6''
Packit Service 1d0348
FIFO node.
Packit Service 1d0348
.TP
Packit Service 1d0348
``7''
Packit Service 1d0348
Reserved.
Packit Service 1d0348
.TP
Packit Service 1d0348
Other
Packit Service 1d0348
A POSIX-compliant implementation must treat any unrecognized typeflag value
Packit Service 1d0348
as a regular file.
Packit Service 1d0348
In particular, writers should ensure that all entries
Packit Service 1d0348
have a valid filename so that they can be restored by readers that do not
Packit Service 1d0348
support the corresponding extension.
Packit Service 1d0348
Uppercase letters "A" through "Z" are reserved for custom extensions.
Packit Service 1d0348
Note that sockets and whiteout entries are not archivable.
Packit Service 1d0348
.RE
Packit Service 1d0348
It is worth noting that the
Packit Service 1d0348
\fIsize\fP
Packit Service 1d0348
field, in particular, has different meanings depending on the type.
Packit Service 1d0348
For regular files, of course, it indicates the amount of data
Packit Service 1d0348
following the header.
Packit Service 1d0348
For directories, it may be used to indicate the total size of all
Packit Service 1d0348
files in the directory, for use by operating systems that pre-allocate
Packit Service 1d0348
directory space.
Packit Service 1d0348
For all other types, it should be set to zero by writers and ignored
Packit Service 1d0348
by readers.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fImagic\fP
Packit Service 1d0348
Contains the magic value
Packit Service 1d0348
``ustar''
Packit Service 1d0348
followed by a NUL byte to indicate that this is a POSIX standard archive.
Packit Service 1d0348
Full compliance requires the uname and gname fields be properly set.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIversion\fP
Packit Service 1d0348
Version.
Packit Service 1d0348
This should be
Packit Service 1d0348
``00''
Packit Service 1d0348
(two copies of the ASCII digit zero) for POSIX standard archives.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIuname\fP, \fIgname\fP
Packit Service 1d0348
User and group names, as null-terminated ASCII strings.
Packit Service 1d0348
These should be used in preference to the uid/gid values
Packit Service 1d0348
when they are set and the corresponding names exist on
Packit Service 1d0348
the system.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIdevmajor\fP, \fIdevminor\fP
Packit Service 1d0348
Major and minor numbers for character device or block device entry.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIname\fP, \fIprefix\fP
Packit Service 1d0348
If the pathname is too long to fit in the 100 bytes provided by the standard
Packit Service 1d0348
format, it can be split at any
Packit Service 1d0348
\fI/\fP
Packit Service 1d0348
character with the first portion going into the prefix field.
Packit Service 1d0348
If the prefix field is not empty, the reader will prepend
Packit Service 1d0348
the prefix value and a
Packit Service 1d0348
\fI/\fP
Packit Service 1d0348
character to the regular name field to obtain the full pathname.
Packit Service 1d0348
The standard does not require a trailing
Packit Service 1d0348
\fI/\fP
Packit Service 1d0348
character on directory names, though most implementations still
Packit Service 1d0348
include this for compatibility reasons.
Packit Service 1d0348
.RE
Packit Service 1d0348
.PP
Packit Service 1d0348
Note that all unused bytes must be set to
Packit Service 1d0348
.BR NUL.
Packit Service 1d0348
.PP
Packit Service 1d0348
Field termination is specified slightly differently by POSIX
Packit Service 1d0348
than by previous implementations.
Packit Service 1d0348
The
Packit Service 1d0348
\fImagic\fP,
Packit Service 1d0348
\fIuname\fP,
Packit Service 1d0348
and
Packit Service 1d0348
\fIgname\fP
Packit Service 1d0348
fields must have a trailing
Packit Service 1d0348
.BR NUL.
Packit Service 1d0348
The
Packit Service 1d0348
\fIpathname\fP,
Packit Service 1d0348
\fIlinkname\fP,
Packit Service 1d0348
and
Packit Service 1d0348
\fIprefix\fP
Packit Service 1d0348
fields must have a trailing
Packit Service 1d0348
.BR NUL
Packit Service 1d0348
unless they fill the entire field.
Packit Service 1d0348
(In particular, it is possible to store a 256-character pathname if it
Packit Service 1d0348
happens to have a
Packit Service 1d0348
\fI/\fP
Packit Service 1d0348
as the 156th character.)
Packit Service 1d0348
POSIX requires numeric fields to be zero-padded in the front, and requires
Packit Service 1d0348
them to be terminated with either space or
Packit Service 1d0348
.BR NUL
Packit Service 1d0348
characters.
Packit Service 1d0348
.PP
Packit Service 1d0348
Currently, most tar implementations comply with the ustar
Packit Service 1d0348
format, occasionally extending it by adding new fields to the
Packit Service 1d0348
blank area at the end of the header record.
Packit Service 1d0348
.SS Numeric Extensions
Packit Service 1d0348
There have been several attempts to extend the range of sizes
Packit Service 1d0348
or times supported by modifying how numbers are stored in the
Packit Service 1d0348
header.
Packit Service 1d0348
.PP
Packit Service 1d0348
One obvious extension to increase the size of files is to
Packit Service 1d0348
eliminate the terminating characters from the various
Packit Service 1d0348
numeric fields.
Packit Service 1d0348
For example, the standard only allows the size field to contain
Packit Service 1d0348
11 octal digits, reserving the twelfth byte for a trailing
Packit Service 1d0348
NUL character.
Packit Service 1d0348
Allowing 12 octal digits allows file sizes up to 64 GB.
Packit Service 1d0348
.PP
Packit Service 1d0348
Another extension, utilized by GNU tar, star, and other newer
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
implementations, permits binary numbers in the standard numeric fields.
Packit Service 1d0348
This is flagged by setting the high bit of the first byte.
Packit Service 1d0348
The remainder of the field is treated as a signed twos-complement
Packit Service 1d0348
value.
Packit Service 1d0348
This permits 95-bit values for the length and time fields
Packit Service 1d0348
and 63-bit values for the uid, gid, and device numbers.
Packit Service 1d0348
In particular, this provides a consistent way to handle
Packit Service 1d0348
negative time values.
Packit Service 1d0348
GNU tar supports this extension for the
Packit Service 1d0348
length, mtime, ctime, and atime fields.
Packit Service 1d0348
Joerg Schilling's star program and the libarchive library support
Packit Service 1d0348
this extension for all numeric fields.
Packit Service 1d0348
Note that this extension is largely obsoleted by the extended
Packit Service 1d0348
attribute record provided by the pax interchange format.
Packit Service 1d0348
.PP
Packit Service 1d0348
Another early GNU extension allowed base-64 values rather than octal.
Packit Service 1d0348
This extension was short-lived and is no longer supported by any
Packit Service 1d0348
implementation.
Packit Service 1d0348
.SS Pax Interchange Format
Packit Service 1d0348
There are many attributes that cannot be portably stored in a
Packit Service 1d0348
POSIX ustar archive.
Packit Service 1d0348
IEEE Std 1003.1-2001 (``POSIX.1'')
Packit Service 1d0348
defined a
Packit Service 1d0348
``pax interchange format''
Packit Service 1d0348
that uses two new types of entries to hold text-formatted
Packit Service 1d0348
metadata that applies to following entries.
Packit Service 1d0348
Note that a pax interchange format archive is a ustar archive in every
Packit Service 1d0348
respect.
Packit Service 1d0348
The new data is stored in ustar-compatible archive entries that use the
Packit Service 1d0348
``x''
Packit Service 1d0348
or
Packit Service 1d0348
``g''
Packit Service 1d0348
typeflag.
Packit Service 1d0348
In particular, older implementations that do not fully support these
Packit Service 1d0348
extensions will extract the metadata into regular files, where the
Packit Service 1d0348
metadata can be examined as necessary.
Packit Service 1d0348
.PP
Packit Service 1d0348
An entry in a pax interchange format archive consists of one or
Packit Service 1d0348
two standard ustar entries, each with its own header and data.
Packit Service 1d0348
The first optional entry stores the extended attributes
Packit Service 1d0348
for the following entry.
Packit Service 1d0348
This optional first entry has an "x" typeflag and a size field that
Packit Service 1d0348
indicates the total size of the extended attributes.
Packit Service 1d0348
The extended attributes themselves are stored as a series of text-format
Packit Service 1d0348
lines encoded in the portable UTF-8 encoding.
Packit Service 1d0348
Each line consists of a decimal number, a space, a key string, an equals
Packit Service 1d0348
sign, a value string, and a new line.
Packit Service 1d0348
The decimal number indicates the length of the entire line, including the
Packit Service 1d0348
initial length field and the trailing newline.
Packit Service 1d0348
An example of such a field is:
Packit Service 1d0348
.RS 4
Packit Service 1d0348
25 ctime=1084839148.1212\en
Packit Service 1d0348
.RE
Packit Service 1d0348
Keys in all lowercase are standard keys.
Packit Service 1d0348
Vendors can add their own keys by prefixing them with an all uppercase
Packit Service 1d0348
vendor name and a period.
Packit Service 1d0348
Note that, unlike the historic header, numeric values are stored using
Packit Service 1d0348
decimal, not octal.
Packit Service 1d0348
A description of some common keys follows:
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBatime\fP, \fBctime\fP, \fBmtime\fP
Packit Service 1d0348
File access, inode change, and modification times.
Packit Service 1d0348
These fields can be negative or include a decimal point and a fractional value.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBhdrcharset\fP
Packit Service 1d0348
The character set used by the pax extension values.
Packit Service 1d0348
By default, all textual values in the pax extended attributes
Packit Service 1d0348
are assumed to be in UTF-8, including pathnames, user names,
Packit Service 1d0348
and group names.
Packit Service 1d0348
In some cases, it is not possible to translate local
Packit Service 1d0348
conventions into UTF-8.
Packit Service 1d0348
If this key is present and the value is the six-character ASCII string
Packit Service 1d0348
``BINARY'',
Packit Service 1d0348
then all textual values are assumed to be in a platform-dependent
Packit Service 1d0348
multi-byte encoding.
Packit Service 1d0348
Note that there are only two valid values for this key:
Packit Service 1d0348
``BINARY''
Packit Service 1d0348
or
Packit Service 1d0348
``ISO-IR\ 10646\ 2000\ UTF-8''.
Packit Service 1d0348
No other values are permitted by the standard, and
Packit Service 1d0348
the latter value should generally not be used as it is the
Packit Service 1d0348
default when this key is not specified.
Packit Service 1d0348
In particular, this flag should not be used as a general
Packit Service 1d0348
mechanism to allow filenames to be stored in arbitrary
Packit Service 1d0348
encodings.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBuname\fP, \fBuid\fP, \fBgname\fP, \fBgid\fP
Packit Service 1d0348
User name, group name, and numeric UID and GID values.
Packit Service 1d0348
The user name and group name stored here are encoded in UTF8
Packit Service 1d0348
and can thus include non-ASCII characters.
Packit Service 1d0348
The UID and GID fields can be of arbitrary length.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBlinkpath\fP
Packit Service 1d0348
The full path of the linked-to file.
Packit Service 1d0348
Note that this is encoded in UTF8 and can thus include non-ASCII characters.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBpath\fP
Packit Service 1d0348
The full pathname of the entry.
Packit Service 1d0348
Note that this is encoded in UTF8 and can thus include non-ASCII characters.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBrealtime.*\fP, \fBsecurity.*\fP
Packit Service 1d0348
These keys are reserved and may be used for future standardization.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBsize\fP
Packit Service 1d0348
The size of the file.
Packit Service 1d0348
Note that there is no length limit on this field, allowing conforming
Packit Service 1d0348
archives to store files much larger than the historic 8GB limit.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBSCHILY.*\fP
Packit Service 1d0348
Vendor-specific attributes used by Joerg Schilling's
Packit Service 1d0348
\fB\%star\fP
Packit Service 1d0348
implementation.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBSCHILY.acl.access\fP, \fBSCHILY.acl.default,\fP \fBSCHILY.acl.ace\fP
Packit Service 1d0348
Stores the access, default and NFSv4 ACLs as textual strings in a format
Packit Service 1d0348
that is an extension of the format specified by POSIX.1e draft 17.
Packit Service 1d0348
In particular, each user or group access specification can include
Packit Service 1d0348
an additional colon-separated field with the numeric UID or GID.
Packit Service 1d0348
This allows ACLs to be restored on systems that may not have complete
Packit Service 1d0348
user or group information available (such as when NIS/YP or LDAP services
Packit Service 1d0348
are temporarily unavailable).
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBSCHILY.devminor\fP, \fBSCHILY.devmajor\fP
Packit Service 1d0348
The full minor and major numbers for device nodes.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBSCHILY.fflags\fP
Packit Service 1d0348
The file flags.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBSCHILY.realsize\fP
Packit Service 1d0348
The full size of the file on disk.
Packit Service 1d0348
XXX explain? XXX
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBSCHILY.dev,\fP \fBSCHILY.ino\fP, \fBSCHILY.nlinks\fP
Packit Service 1d0348
The device number, inode number, and link count for the entry.
Packit Service 1d0348
In particular, note that a pax interchange format archive using Joerg
Packit Service 1d0348
Schilling's
Packit Service 1d0348
\fBSCHILY.*\fP
Packit Service 1d0348
extensions can store all of the data from
Packit Service 1d0348
\fIstruct\fP stat.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBLIBARCHIVE.*\fP
Packit Service 1d0348
Vendor-specific attributes used by the
Packit Service 1d0348
\fB\%libarchive\fP
Packit Service 1d0348
library and programs that use it.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBLIBARCHIVE.creationtime\fP
Packit Service 1d0348
The time when the file was created.
Packit Service 1d0348
(This should not be confused with the POSIX
Packit Service 1d0348
``ctime''
Packit Service 1d0348
attribute, which refers to the time when the file
Packit Service 1d0348
metadata was last changed.)
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBLIBARCHIVE.xattr.\fP \fInamespace\fP.\fIkey\fP
Packit Service 1d0348
Libarchive stores POSIX.1e-style extended attributes using
Packit Service 1d0348
keys of this form.
Packit Service 1d0348
The
Packit Service 1d0348
\fIkey\fP
Packit Service 1d0348
value is URL-encoded:
Packit Service 1d0348
All non-ASCII characters and the two special characters
Packit Service 1d0348
``=''
Packit Service 1d0348
and
Packit Service 1d0348
``%''
Packit Service 1d0348
are encoded as
Packit Service 1d0348
``%''
Packit Service 1d0348
followed by two uppercase hexadecimal digits.
Packit Service 1d0348
The value of this key is the extended attribute value
Packit Service 1d0348
encoded in base 64.
Packit Service 1d0348
XXX Detail the base-64 format here XXX
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBVENDOR.*\fP
Packit Service 1d0348
XXX document other vendor-specific extensions XXX
Packit Service 1d0348
.RE
Packit Service 1d0348
.PP
Packit Service 1d0348
Any values stored in an extended attribute override the corresponding
Packit Service 1d0348
values in the regular tar header.
Packit Service 1d0348
Note that compliant readers should ignore the regular fields when they
Packit Service 1d0348
are overridden.
Packit Service 1d0348
This is important, as existing archivers are known to store non-compliant
Packit Service 1d0348
values in the standard header fields in this situation.
Packit Service 1d0348
There are no limits on length for any of these fields.
Packit Service 1d0348
In particular, numeric fields can be arbitrarily large.
Packit Service 1d0348
All text fields are encoded in UTF8.
Packit Service 1d0348
Compliant writers should store only portable 7-bit ASCII characters in
Packit Service 1d0348
the standard ustar header and use extended
Packit Service 1d0348
attributes whenever a text value contains non-ASCII characters.
Packit Service 1d0348
.PP
Packit Service 1d0348
In addition to the
Packit Service 1d0348
\fBx\fP
Packit Service 1d0348
entry described above, the pax interchange format
Packit Service 1d0348
also supports a
Packit Service 1d0348
\fBg\fP
Packit Service 1d0348
entry.
Packit Service 1d0348
The
Packit Service 1d0348
\fBg\fP
Packit Service 1d0348
entry is identical in format, but specifies attributes that serve as
Packit Service 1d0348
defaults for all subsequent archive entries.
Packit Service 1d0348
The
Packit Service 1d0348
\fBg\fP
Packit Service 1d0348
entry is not widely used.
Packit Service 1d0348
.PP
Packit Service 1d0348
Besides the new
Packit Service 1d0348
\fBx\fP
Packit Service 1d0348
and
Packit Service 1d0348
\fBg\fP
Packit Service 1d0348
entries, the pax interchange format has a few other minor variations
Packit Service 1d0348
from the earlier ustar format.
Packit Service 1d0348
The most troubling one is that hardlinks are permitted to have
Packit Service 1d0348
data following them.
Packit Service 1d0348
This allows readers to restore any hardlink to a file without
Packit Service 1d0348
having to rewind the archive to find an earlier entry.
Packit Service 1d0348
However, it creates complications for robust readers, as it is no longer
Packit Service 1d0348
clear whether or not they should ignore the size field for hardlink entries.
Packit Service 1d0348
.SS GNU Tar Archives
Packit Service 1d0348
The GNU tar program started with a pre-POSIX format similar to that
Packit Service 1d0348
described earlier and has extended it using several different mechanisms:
Packit Service 1d0348
It added new fields to the empty space in the header (some of which was later
Packit Service 1d0348
used by POSIX for conflicting purposes);
Packit Service 1d0348
it allowed the header to be continued over multiple records;
Packit Service 1d0348
and it defined new entries that modify following entries
Packit Service 1d0348
(similar in principle to the
Packit Service 1d0348
\fBx\fP
Packit Service 1d0348
entry described above, but each GNU special entry is single-purpose,
Packit Service 1d0348
unlike the general-purpose
Packit Service 1d0348
\fBx\fP
Packit Service 1d0348
entry).
Packit Service 1d0348
As a result, GNU tar archives are not POSIX compatible, although
Packit Service 1d0348
more lenient POSIX-compliant readers can successfully extract most
Packit Service 1d0348
GNU tar archives.
Packit Service 1d0348
.RS 4
Packit Service 1d0348
.nf
Packit Service 1d0348
struct header_gnu_tar {
Packit Service 1d0348
	char name[100];
Packit Service 1d0348
	char mode[8];
Packit Service 1d0348
	char uid[8];
Packit Service 1d0348
	char gid[8];
Packit Service 1d0348
	char size[12];
Packit Service 1d0348
	char mtime[12];
Packit Service 1d0348
	char checksum[8];
Packit Service 1d0348
	char typeflag[1];
Packit Service 1d0348
	char linkname[100];
Packit Service 1d0348
	char magic[6];
Packit Service 1d0348
	char version[2];
Packit Service 1d0348
	char uname[32];
Packit Service 1d0348
	char gname[32];
Packit Service 1d0348
	char devmajor[8];
Packit Service 1d0348
	char devminor[8];
Packit Service 1d0348
	char atime[12];
Packit Service 1d0348
	char ctime[12];
Packit Service 1d0348
	char offset[12];
Packit Service 1d0348
	char longnames[4];
Packit Service 1d0348
	char unused[1];
Packit Service 1d0348
	struct {
Packit Service 1d0348
		char offset[12];
Packit Service 1d0348
		char numbytes[12];
Packit Service 1d0348
	} sparse[4];
Packit Service 1d0348
	char isextended[1];
Packit Service 1d0348
	char realsize[12];
Packit Service 1d0348
	char pad[17];
Packit Service 1d0348
};
Packit Service 1d0348
.RE
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
\fItypeflag\fP
Packit Service 1d0348
GNU tar uses the following special entry types, in addition to
Packit Service 1d0348
those defined by POSIX:
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
7
Packit Service 1d0348
GNU tar treats type "7" records identically to type "0" records,
Packit Service 1d0348
except on one obscure RTOS where they are used to indicate the
Packit Service 1d0348
pre-allocation of a contiguous file on disk.
Packit Service 1d0348
.TP
Packit Service 1d0348
D
Packit Service 1d0348
This indicates a directory entry.
Packit Service 1d0348
Unlike the POSIX-standard "5"
Packit Service 1d0348
typeflag, the header is followed by data records listing the names
Packit Service 1d0348
of files in this directory.
Packit Service 1d0348
Each name is preceded by an ASCII "Y"
Packit Service 1d0348
if the file is stored in this archive or "N" if the file is not
Packit Service 1d0348
stored in this archive.
Packit Service 1d0348
Each name is terminated with a null, and
Packit Service 1d0348
an extra null marks the end of the name list.
Packit Service 1d0348
The purpose of this
Packit Service 1d0348
entry is to support incremental backups; a program restoring from
Packit Service 1d0348
such an archive may wish to delete files on disk that did not exist
Packit Service 1d0348
in the directory when the archive was made.
Packit Service 1d0348
.PP
Packit Service 1d0348
Note that the "D" typeflag specifically violates POSIX, which requires
Packit Service 1d0348
that unrecognized typeflags be restored as normal files.
Packit Service 1d0348
In this case, restoring the "D" entry as a file could interfere
Packit Service 1d0348
with subsequent creation of the like-named directory.
Packit Service 1d0348
.TP
Packit Service 1d0348
K
Packit Service 1d0348
The data for this entry is a long linkname for the following regular entry.
Packit Service 1d0348
.TP
Packit Service 1d0348
L
Packit Service 1d0348
The data for this entry is a long pathname for the following regular entry.
Packit Service 1d0348
.TP
Packit Service 1d0348
M
Packit Service 1d0348
This is a continuation of the last file on the previous volume.
Packit Service 1d0348
GNU multi-volume archives guarantee that each volume begins with a valid
Packit Service 1d0348
entry header.
Packit Service 1d0348
To ensure this, a file may be split, with part stored at the end of one volume,
Packit Service 1d0348
and part stored at the beginning of the next volume.
Packit Service 1d0348
The "M" typeflag indicates that this entry continues an existing file.
Packit Service 1d0348
Such entries can only occur as the first or second entry
Packit Service 1d0348
in an archive (the latter only if the first entry is a volume label).
Packit Service 1d0348
The
Packit Service 1d0348
\fIsize\fP
Packit Service 1d0348
field specifies the size of this entry.
Packit Service 1d0348
The
Packit Service 1d0348
\fIoffset\fP
Packit Service 1d0348
field at bytes 369-380 specifies the offset where this file fragment
Packit Service 1d0348
begins.
Packit Service 1d0348
The
Packit Service 1d0348
\fIrealsize\fP
Packit Service 1d0348
field specifies the total size of the file (which must equal
Packit Service 1d0348
\fIsize\fP
Packit Service 1d0348
plus
Packit Service 1d0348
\fIoffset\fP).
Packit Service 1d0348
When extracting, GNU tar checks that the header file name is the one it is
Packit Service 1d0348
expecting, that the header offset is in the correct sequence, and that
Packit Service 1d0348
the sum of offset and size is equal to realsize.
Packit Service 1d0348
.TP
Packit Service 1d0348
N
Packit Service 1d0348
Type "N" records are no longer generated by GNU tar.
Packit Service 1d0348
They contained a
Packit Service 1d0348
list of files to be renamed or symlinked after extraction; this was
Packit Service 1d0348
originally used to support long names.
Packit Service 1d0348
The contents of this record
Packit Service 1d0348
are a text description of the operations to be done, in the form
Packit Service 1d0348
``Rename %s to %s\en''
Packit Service 1d0348
or
Packit Service 1d0348
``Symlink %s to %s\en ;''
Packit Service 1d0348
in either case, both
Packit Service 1d0348
filenames are escaped using K&R C syntax.
Packit Service 1d0348
Due to security concerns, "N" records are now generally ignored
Packit Service 1d0348
when reading archives.
Packit Service 1d0348
.TP
Packit Service 1d0348
S
Packit Service 1d0348
This is a
Packit Service 1d0348
``sparse''
Packit Service 1d0348
regular file.
Packit Service 1d0348
Sparse files are stored as a series of fragments.
Packit Service 1d0348
The header contains a list of fragment offset/length pairs.
Packit Service 1d0348
If more than four such entries are required, the header is
Packit Service 1d0348
extended as necessary with
Packit Service 1d0348
``extra''
Packit Service 1d0348
header extensions (an older format that is no longer used), or
Packit Service 1d0348
``sparse''
Packit Service 1d0348
extensions.
Packit Service 1d0348
.TP
Packit Service 1d0348
V
Packit Service 1d0348
The
Packit Service 1d0348
\fIname\fP
Packit Service 1d0348
field should be interpreted as a tape/volume header name.
Packit Service 1d0348
This entry should generally be ignored on extraction.
Packit Service 1d0348
.RE
Packit Service 1d0348
.TP
Packit Service 1d0348
\fImagic\fP
Packit Service 1d0348
The magic field holds the five characters
Packit Service 1d0348
``ustar''
Packit Service 1d0348
followed by a space.
Packit Service 1d0348
Note that POSIX ustar archives have a trailing null.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIversion\fP
Packit Service 1d0348
The version field holds a space character followed by a null.
Packit Service 1d0348
Note that POSIX ustar archives use two copies of the ASCII digit
Packit Service 1d0348
``0''.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIatime\fP, \fIctime\fP
Packit Service 1d0348
The time the file was last accessed and the time of
Packit Service 1d0348
last change of file information, stored in octal as with
Packit Service 1d0348
\fImtime\fP.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIlongnames\fP
Packit Service 1d0348
This field is apparently no longer used.
Packit Service 1d0348
.TP
Packit Service 1d0348
Sparse \fIoffset\fP / \fInumbytes\fP
Packit Service 1d0348
Each such structure specifies a single fragment of a sparse
Packit Service 1d0348
file.
Packit Service 1d0348
The two fields store values as octal numbers.
Packit Service 1d0348
The fragments are each padded to a multiple of 512 bytes
Packit Service 1d0348
in the archive.
Packit Service 1d0348
On extraction, the list of fragments is collected from the
Packit Service 1d0348
header (including any extension headers), and the data
Packit Service 1d0348
is then read and written to the file at appropriate offsets.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIisextended\fP
Packit Service 1d0348
If this is set to non-zero, the header will be followed by additional
Packit Service 1d0348
``sparse header''
Packit Service 1d0348
records.
Packit Service 1d0348
Each such record contains information about as many as 21 additional
Packit Service 1d0348
sparse blocks as shown here:
Packit Service 1d0348
.RS 4
Packit Service 1d0348
.nf
Packit Service 1d0348
struct gnu_sparse_header {
Packit Service 1d0348
	struct {
Packit Service 1d0348
		char offset[12];
Packit Service 1d0348
		char numbytes[12];
Packit Service 1d0348
	} sparse[21];
Packit Service 1d0348
	char    isextended[1];
Packit Service 1d0348
	char    padding[7];
Packit Service 1d0348
};
Packit Service 1d0348
.RE
Packit Service 1d0348
.TP
Packit Service 1d0348
\fIrealsize\fP
Packit Service 1d0348
A binary representation of the file's complete size, with a much larger range
Packit Service 1d0348
than the POSIX file size.
Packit Service 1d0348
In particular, with
Packit Service 1d0348
\fBM\fP
Packit Service 1d0348
type files, the current entry is only a portion of the file.
Packit Service 1d0348
In that case, the POSIX size field will indicate the size of this
Packit Service 1d0348
entry; the
Packit Service 1d0348
\fIrealsize\fP
Packit Service 1d0348
field will indicate the total size of the file.
Packit Service 1d0348
.RE
Packit Service 1d0348
.SS GNU tar pax archives
Packit Service 1d0348
GNU tar 1.14 (XXX check this XXX) and later will write
Packit Service 1d0348
pax interchange format archives when you specify the
Packit Service 1d0348
\fB\--posix\fP
Packit Service 1d0348
flag.
Packit Service 1d0348
This format follows the pax interchange format closely,
Packit Service 1d0348
using some
Packit Service 1d0348
\fBSCHILY\fP
Packit Service 1d0348
tags and introducing new keywords to store sparse file information.
Packit Service 1d0348
There have been three iterations of the sparse file support, referred to
Packit Service 1d0348
as
Packit Service 1d0348
``0.0'',
Packit Service 1d0348
``0.1'',
Packit Service 1d0348
and
Packit Service 1d0348
``1.0''.
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBGNU.sparse.numblocks\fP, \fBGNU.sparse.offset\fP, \fBGNU.sparse.numbytes\fP, \fBGNU.sparse.size\fP
Packit Service 1d0348
The
Packit Service 1d0348
``0.0''
Packit Service 1d0348
format used an initial
Packit Service 1d0348
\fBGNU.sparse.numblocks\fP
Packit Service 1d0348
attribute to indicate the number of blocks in the file, a pair of
Packit Service 1d0348
\fBGNU.sparse.offset\fP
Packit Service 1d0348
and
Packit Service 1d0348
\fBGNU.sparse.numbytes\fP
Packit Service 1d0348
to indicate the offset and size of each block,
Packit Service 1d0348
and a single
Packit Service 1d0348
\fBGNU.sparse.size\fP
Packit Service 1d0348
to indicate the full size of the file.
Packit Service 1d0348
This is not the same as the size in the tar header because the
Packit Service 1d0348
latter value does not include the size of any holes.
Packit Service 1d0348
This format required that the order of attributes be preserved and
Packit Service 1d0348
relied on readers accepting multiple appearances of the same attribute
Packit Service 1d0348
names, which is not officially permitted by the standards.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBGNU.sparse.map\fP
Packit Service 1d0348
The
Packit Service 1d0348
``0.1''
Packit Service 1d0348
format used a single attribute that stored a comma-separated
Packit Service 1d0348
list of decimal numbers.
Packit Service 1d0348
Each pair of numbers indicated the offset and size, respectively,
Packit Service 1d0348
of a block of data.
Packit Service 1d0348
This does not work well if the archive is extracted by an archiver
Packit Service 1d0348
that does not recognize this extension, since many pax implementations
Packit Service 1d0348
simply discard unrecognized attributes.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBGNU.sparse.major\fP, \fBGNU.sparse.minor\fP, \fBGNU.sparse.name\fP, \fBGNU.sparse.realsize\fP
Packit Service 1d0348
The
Packit Service 1d0348
``1.0''
Packit Service 1d0348
format stores the sparse block map in one or more 512-byte blocks
Packit Service 1d0348
prepended to the file data in the entry body.
Packit Service 1d0348
The pax attributes indicate the existence of this map
Packit Service 1d0348
(via the
Packit Service 1d0348
\fBGNU.sparse.major\fP
Packit Service 1d0348
and
Packit Service 1d0348
\fBGNU.sparse.minor\fP
Packit Service 1d0348
fields)
Packit Service 1d0348
and the full size of the file.
Packit Service 1d0348
The
Packit Service 1d0348
\fBGNU.sparse.name\fP
Packit Service 1d0348
holds the true name of the file.
Packit Service 1d0348
To avoid confusion, the name stored in the regular tar header
Packit Service 1d0348
is a modified name so that extraction errors will be apparent
Packit Service 1d0348
to users.
Packit Service 1d0348
.RE
Packit Service 1d0348
.SS Solaris Tar
Packit Service 1d0348
XXX More Details Needed XXX
Packit Service 1d0348
.PP
Packit Service 1d0348
Solaris tar (beginning with SunOS XXX 5.7 ?? XXX) supports an
Packit Service 1d0348
``extended''
Packit Service 1d0348
format that is fundamentally similar to pax interchange format,
Packit Service 1d0348
with the following differences:
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.IP \(bu
Packit Service 1d0348
Extended attributes are stored in an entry whose type is
Packit Service 1d0348
\fBX\fP,
Packit Service 1d0348
not
Packit Service 1d0348
\fBx\fP,
Packit Service 1d0348
as used by pax interchange format.
Packit Service 1d0348
The detailed format of this entry appears to be the same
Packit Service 1d0348
as detailed above for the
Packit Service 1d0348
\fBx\fP
Packit Service 1d0348
entry.
Packit Service 1d0348
.IP \(bu
Packit Service 1d0348
An additional
Packit Service 1d0348
\fBA\fP
Packit Service 1d0348
header is used to store an ACL for the following regular entry.
Packit Service 1d0348
The body of this entry contains a seven-digit octal number
Packit Service 1d0348
followed by a zero byte, followed by the
Packit Service 1d0348
textual ACL description.
Packit Service 1d0348
The octal value is the number of ACL entries
Packit Service 1d0348
plus a constant that indicates the ACL type: 01000000
Packit Service 1d0348
for POSIX.1e ACLs and 03000000 for NFSv4 ACLs.
Packit Service 1d0348
.RE
Packit Service 1d0348
.SS AIX Tar
Packit Service 1d0348
XXX More details needed XXX
Packit Service 1d0348
.PP
Packit Service 1d0348
AIX Tar uses a ustar-formatted header with the type
Packit Service 1d0348
\fBA\fP
Packit Service 1d0348
for storing coded ACL information.
Packit Service 1d0348
Unlike the Solaris format, AIX tar writes this header after the
Packit Service 1d0348
regular file body to which it applies.
Packit Service 1d0348
The pathname in this header is either
Packit Service 1d0348
\fBNFS4\fP
Packit Service 1d0348
or
Packit Service 1d0348
\fBAIXC\fP
Packit Service 1d0348
to indicate the type of ACL stored.
Packit Service 1d0348
The actual ACL is stored in platform-specific binary format.
Packit Service 1d0348
.SS Mac OS X Tar
Packit Service 1d0348
The tar distributed with Apple's Mac OS X stores most regular files
Packit Service 1d0348
as two separate files in the tar archive.
Packit Service 1d0348
The two files have the same name except that the first
Packit Service 1d0348
one has
Packit Service 1d0348
``._''
Packit Service 1d0348
prepended to the last path element.
Packit Service 1d0348
This special file stores an AppleDouble-encoded
Packit Service 1d0348
binary blob with additional metadata about the second file,
Packit Service 1d0348
including ACL, extended attributes, and resources.
Packit Service 1d0348
To recreate the original file on disk, each
Packit Service 1d0348
separate file can be extracted and the Mac OS X
Packit Service 1d0348
\fB\%copyfile\fP()
Packit Service 1d0348
function can be used to unpack the separate
Packit Service 1d0348
metadata file and apply it to th regular file.
Packit Service 1d0348
Conversely, the same function provides a
Packit Service 1d0348
``pack''
Packit Service 1d0348
option to encode the extended metadata from
Packit Service 1d0348
a file into a separate file whose contents
Packit Service 1d0348
can then be put into a tar archive.
Packit Service 1d0348
.PP
Packit Service 1d0348
Note that the Apple extended attributes interact
Packit Service 1d0348
badly with long filenames.
Packit Service 1d0348
Since each file is stored with the full name,
Packit Service 1d0348
a separate set of extensions needs to be included
Packit Service 1d0348
in the archive for each one, doubling the overhead
Packit Service 1d0348
required for files with long names.
Packit Service 1d0348
.SS Summary of tar type codes
Packit Service 1d0348
The following list is a condensed summary of the type codes
Packit Service 1d0348
used in tar header records generated by different tar implementations.
Packit Service 1d0348
More details about specific implementations can be found above:
Packit Service 1d0348
.RS 5
Packit Service 1d0348
.TP
Packit Service 1d0348
NUL
Packit Service 1d0348
Early tar programs stored a zero byte for regular files.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB0\fP
Packit Service 1d0348
POSIX standard type code for a regular file.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB1\fP
Packit Service 1d0348
POSIX standard type code for a hard link description.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB2\fP
Packit Service 1d0348
POSIX standard type code for a symbolic link description.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB3\fP
Packit Service 1d0348
POSIX standard type code for a character device node.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB4\fP
Packit Service 1d0348
POSIX standard type code for a block device node.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB5\fP
Packit Service 1d0348
POSIX standard type code for a directory.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB6\fP
Packit Service 1d0348
POSIX standard type code for a FIFO.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB7\fP
Packit Service 1d0348
POSIX reserved.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fB7\fP
Packit Service 1d0348
GNU tar used for pre-allocated files on some systems.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBA\fP
Packit Service 1d0348
Solaris tar ACL description stored prior to a regular file header.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBA\fP
Packit Service 1d0348
AIX tar ACL description stored after the file body.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBD\fP
Packit Service 1d0348
GNU tar directory dump.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBK\fP
Packit Service 1d0348
GNU tar long linkname for the following header.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBL\fP
Packit Service 1d0348
GNU tar long pathname for the following header.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBM\fP
Packit Service 1d0348
GNU tar multivolume marker, indicating the file is a continuation of a file from the previous volume.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBN\fP
Packit Service 1d0348
GNU tar long filename support.  Deprecated.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBS\fP
Packit Service 1d0348
GNU tar sparse regular file.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBV\fP
Packit Service 1d0348
GNU tar tape/volume header name.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBX\fP
Packit Service 1d0348
Solaris tar general-purpose extension header.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBg\fP
Packit Service 1d0348
POSIX pax interchange format global extensions.
Packit Service 1d0348
.TP
Packit Service 1d0348
\fBx\fP
Packit Service 1d0348
POSIX pax interchange format per-file extensions.
Packit Service 1d0348
.RE
Packit Service 1d0348
.SH SEE ALSO
Packit Service 1d0348
.ad l
Packit Service 1d0348
\fBar\fP(1),
Packit Service 1d0348
\fBpax\fP(1),
Packit Service 1d0348
\fBtar\fP(1)
Packit Service 1d0348
.SH STANDARDS
Packit Service 1d0348
.ad l
Packit Service 1d0348
The
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
utility is no longer a part of POSIX or the Single Unix Standard.
Packit Service 1d0348
It last appeared in
Packit Service 1d0348
Version 2 of the Single UNIX Specification (``SUSv2'').
Packit Service 1d0348
It has been supplanted in subsequent standards by
Packit Service 1d0348
\fBpax\fP(1).
Packit Service 1d0348
The ustar format is currently part of the specification for the
Packit Service 1d0348
\fBpax\fP(1)
Packit Service 1d0348
utility.
Packit Service 1d0348
The pax interchange file format is new with
Packit Service 1d0348
IEEE Std 1003.1-2001 (``POSIX.1'').
Packit Service 1d0348
.SH HISTORY
Packit Service 1d0348
.ad l
Packit Service 1d0348
A
Packit Service 1d0348
\fB\%tar\fP
Packit Service 1d0348
command appeared in Seventh Edition Unix, which was released in January, 1979.
Packit Service 1d0348
It replaced the
Packit Service 1d0348
\fB\%tp\fP
Packit Service 1d0348
program from Fourth Edition Unix which in turn replaced the
Packit Service 1d0348
\fB\%tap\fP
Packit Service 1d0348
program from First Edition Unix.
Packit Service 1d0348
John Gilmore's
Packit Service 1d0348
\fB\%pdtar\fP
Packit Service 1d0348
public-domain implementation (circa 1987) was highly influential
Packit Service 1d0348
and formed the basis of
Packit Service 1d0348
\fB\%GNU\fP tar
Packit Service 1d0348
(circa 1988).
Packit Service 1d0348
Joerg Shilling's
Packit Service 1d0348
\fB\%star\fP
Packit Service 1d0348
archiver is another open-source (CDDL) archiver (originally developed
Packit Service 1d0348
circa 1985) which features complete support for pax interchange
Packit Service 1d0348
format.
Packit Service 1d0348
.PP
Packit Service 1d0348
This documentation was written as part of the
Packit Service 1d0348
\fB\%libarchive\fP
Packit Service 1d0348
and
Packit Service 1d0348
\fB\%bsdtar\fP
Packit Service 1d0348
project by
Packit Service 1d0348
Tim Kientzle \%<kientzle@FreeBSD.org.>