Tar/PAX-1

From Get docs

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

E.0.3 PAX Format, Version 1.0

The version 1.0 of sparse format was introduced with GNU tar 1.15.92. Its main objective was to make the resulting file extractable with little effort even by non-posix aware tar implementations. Starting from this version, the extended header preceding a sparse member always contains the following variables that identify the format being used:

GNU.sparse.major
Major version
GNU.sparse.minor
Minor version

The name field in ustar header contains a special name, constructed using the following pattern:

 
%d/GNUSparseFile.%p/%f

The real name of the sparse file is stored in the variable GNU.sparse.name. The real size of the file is stored in the variable GNU.sparse.realsize.

The sparse map itself is stored in the file data block, preceding the actual file data. It consists of a series of decimal numbers delimited by newlines. The map is padded with nulls to the nearest block boundary.

The first number gives the number of entries in the map. Following are map entries, each one consisting of two numbers giving the offset and size of the data block it describes.

The format is designed in such a way that non-posix aware tars and tars not supporting GNU.sparse.* keywords will extract each sparse file in its condensed form with the file map prepended and will place it into a separate directory. Then, using a simple program it would be possible to expand the file to its original form even without GNU tar. See section Extracting Sparse Members, for the detailed information on how to extract sparse members without GNU tar.

This document was generated on February, 23 2019 using texi2html 1.76.