Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > T

tar(4)

HP-UX 11i Version 3: February 2007
» 

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index

NAME

tar — format of tar tape archive

DESCRIPTION

The header structure produced by tar (see tar(1)) is as follows (the array size defined by the constants is shown on the right):

struct { char name[NAMSIZ]; (100) char mode[MODE_SZ]; (8) char uid[UID_SZ]; (8) char gid[GID_SZ]; (8) char size[SIZE_SZ]; (12) char mtime[MTIME_SZ]; (12) char chksum[CHKSUM_SZ]; (8) char typeflag; char linkname[NAMSIZ]; (100) char magic[MAGIC_SZ]; (6) char version[VERSION_SZ]; (2) char uname[UNAME_SZ]; (32) char gname[GNAME_SZ]; (32) char devmajor[DEV_SZ]; (8) char devminor[DEV_SZ]; (8) char prefix[PREFIX_SZ]; (155) } dbuf;

All characters are represented in ASCII. There is no padding used in the header block; all fields are contiguous.

The fields magic, uname, and gname are null-terminated character strings. The fields name, linkname, and prefix are null-terminated character strings except when all characters in the array contain non-null characters, including the last character. The version field is two bytes containing the characters 00 (zero-zero). The typeflag contains a single character. All other fields are leading-zero-filled octal numbers in ASCII. Each numeric field is terminated by one or more space or null characters.

The name and the prefix fields produce the pathname of the file. The hierarchical relationship of the file is retained by specifying the pathname as a path prefix, with a slash character and filename as the suffix. If the prefix contains non-null characters, prefix, a slash character, and name are concatenated without modification or addition of new characters to produce a new pathname. In this manner, pathnames of at most 256 characters can be supported. If a pathname does not fit in the space provided, the format-creating utility notifies the user of the error, and no attempt is made to store any part of the file, header, or data on the medium.

SEE ALSO

tar(1)

STANDARDS CONFORMANCE

tar: XPG4, FIPS 151-2, POSIX.1

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.