1 .\" Copyright (c) 2003-2007 Tim Kientzle
2 .\" All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 .Nd manipulate tape archives
35 .Op Ar bundled-flags Ao args Ac
36 .Op Ao Ar file Ac | Ao Ar pattern Ac ...
40 .Op Ar files | Ar directories
45 .Op Ar files | Ar directories
52 creates and manipulates streaming archive files.
53 This implementation can extract from tar, pax, cpio, zip, jar, ar, xar,
54 rpm, 7-zip, and ISO 9660 cdrom images and can create tar, pax, cpio, ar, zip,
55 7-zip, and shar archives.
57 The first synopsis form shows a
60 This usage is provided for compatibility with historical implementations.
61 See COMPATIBILITY below for details.
63 The other synopsis forms show the preferred usage.
66 is a mode indicator from the following list:
67 .Bl -tag -compact -width indent
69 Create a new archive containing the specified items.
70 The long option form is
75 but new entries are appended to the archive.
76 Note that this only works on uncompressed archives stored in regular files.
80 The long option form is
83 List archive contents to stdout.
84 The long option form is
89 but new entries are added only if they have a modification date
90 newer than the corresponding entry in the archive.
91 Note that this only works on uncompressed archives stored in regular files.
98 Extract to disk from the archive.
99 If a file with the same name appears more than once in the archive,
100 each copy will be extracted, with later copies overwriting (replacing)
102 The long option form is
111 mode, each specified file or directory is added to the
112 archive in the order specified on the command line.
113 By default, the contents of each directory are also archived.
115 In extract or list mode, the entire command line
116 is read and parsed before the archive is opened.
117 The pathnames or patterns on the command line indicate
118 which items in the archive should be processed.
119 Patterns are shell-style globbing patterns as
123 Unless specifically stated otherwise, options are applicable in
125 .Bl -tag -width indent
126 .It Cm @ Ns Pa archive
128 The specified archive is opened and the entries
129 in it will be appended to the current archive.
131 .Dl Nm Fl c Fl f Pa - Pa newfile Cm @ Ns Pa original.tar
132 writes a new archive to standard output containing a file
134 and all of the entries from
137 .Dl Nm Fl c Fl f Pa - Pa newfile Pa original.tar
138 creates a new archive with only two entries.
140 .Dl Nm Fl czf Pa - Fl Fl format Cm pax Cm @ Ns Pa -
141 reads an archive from standard input (whose format will be determined
142 automatically) and converts it into a gzip-compressed
143 pax-format archive on stdout.
146 can be used to convert archives from one format to another.
147 .It Fl a , Fl Fl auto-compress
149 Use the archive suffix to decide a set of the format and
152 .Dl Nm Fl a Fl cf Pa archive.tgz source.c source.h
153 creates a new archive with restricted pax format and gzip compression,
154 .Dl Nm Fl a Fl cf Pa archive.tar.bz2.uu source.c source.h
155 creates a new archive with restricted pax format and bzip2 compression
156 and uuencode compression,
157 .Dl Nm Fl a Fl cf Pa archive.zip source.c source.h
158 creates a new archive with zip format,
159 .Dl Nm Fl a Fl jcf Pa archive.tgz source.c source.h
162 option, and creates a new archive with restricted pax format
163 and gzip compression,
164 .Dl Nm Fl a Fl jcf Pa archive.xxx source.c source.h
165 if it is unknown suffix or no suffix, creates a new archive with
166 restricted pax format and bzip2 compression.
167 .It Fl B , Fl Fl read-full-blocks
168 Ignored for compatibility with other
171 .It Fl b Ar blocksize , Fl Fl block-size Ar blocksize
172 Specify the block size, in 512-byte records, for tape drive I/O.
173 As a rule, this argument is only needed when reading from or writing
174 to tape drives, and usually not even then as the default block size of
175 20 records (10240 bytes) is very common.
176 .It Fl C Ar directory , Fl Fl cd Ar directory , Fl Fl directory Ar directory
177 In c and r mode, this changes the directory before adding
179 In x mode, change directories after opening the archive
180 but before extracting entries from the archive.
184 to the current directory after processing any
186 options and before extracting any files.
187 .It Fl Fl disable-copyfile
191 .It Fl Fl exclude Ar pattern
192 Do not process files or directories that match the
194 Note that exclusions take precedence over patterns or filenames
195 specified on the command line.
196 .It Fl Fl format Ar format
198 Use the specified format for the created archive.
199 Supported formats include
205 Other formats may also be supported; see
206 .Xr libarchive-formats 5
207 for more information about currently-supported formats.
208 In r and u modes, when extending an existing archive, the format specified
209 here must be compatible with the format of the existing archive on disk.
210 .It Fl f Ar file , Fl Fl file Ar file
211 Read the archive from or write the archive to the specified file.
214 for standard input or standard output.
215 The default varies by system;
220 on Linux, the default is
223 Use the provided group id number.
224 On extract, this overrides the group id in the archive;
225 the group name in the archive will be ignored.
226 On create, this overrides the group id read from disk;
229 is not also specified, the group name will be set to
231 .It Fl Fl gname Ar name
232 Use the provided group name.
233 On extract, this overrides the group name in the archive;
234 if the provided group name does not exist on the system,
236 (from the archive or from the
239 will be used instead.
240 On create, this sets the group name that will be stored
242 the name will not be verified against the system group database.
245 Symbolic links named on the command line will be followed; the
246 target of the link will be archived, not the link itself.
256 .It Fl Fl hfsCompression
258 Mac OS X specific(v10.6 or later). Compress extracted regular files with HFS+ compression.
259 .It Fl Fl include Ar pattern
260 Process only files or directories that match the specified pattern.
261 Note that exclusions specified with
263 take precedence over inclusions.
264 If no inclusions are explicitly specified, all entries are processed by
268 option is especially useful when filtering archives.
269 For example, the command
270 .Dl Nm Fl c Fl f Pa new.tar Fl Fl include='*foo*' Cm @ Ns Pa old.tgz
271 creates a new archive
273 containing only the entries from
275 containing the string
279 Compress the resulting archive with
281 In extract or list modes, this option is ignored.
282 Note that, unlike other
284 implementations, this implementation recognizes XZ compression
285 automatically when reading archives.
286 .It Fl j , Fl Fl bzip , Fl Fl bzip2 , Fl Fl bunzip2
288 Compress the resulting archive with
290 In extract or list modes, this option is ignored.
291 Note that, unlike other
293 implementations, this implementation recognizes bzip2 compression
294 automatically when reading archives.
295 .It Fl k , Fl Fl keep-old-files
297 Do not overwrite existing files.
298 In particular, if a file appears more than once in an archive,
299 later copies will not overwrite earlier copies.
300 .It Fl Fl keep-newer-files
302 Do not overwrite existing files that are newer than the
303 versions appearing in the archive being extracted.
304 .It Fl L , Fl Fl dereference
306 All symbolic links will be followed.
307 Normally, symbolic links are archived as such.
308 With this option, the target of the link will be archived instead.
309 .It Fl l , Fl Fl check-links
311 Issue a warning message unless all links to each file are archived.
314 Compress the resulting archive with
316 In extract or list modes, this option is ignored.
318 (c mode only) Compress the resulting archive with the original LZMA algorithm.
319 Use of this option is discouraged and new archives should be created with
322 Note that, unlike other
324 implementations, this implementation recognizes LZMA compression
325 automatically when reading archives.
328 Compress the resulting archive with
330 In extract or list modes, this option is ignored.
331 .It Fl m , Fl Fl modification-time
333 Do not extract modification time.
334 By default, the modification time is set to the time stored in the archive.
335 .It Fl n , Fl Fl norecurse , Fl Fl no-recursion
337 Do not recursively archive the contents of directories.
338 .It Fl Fl newer Ar date
340 Only include files and directories newer than the specified date.
341 This compares ctime entries.
342 .It Fl Fl newer-mtime Ar date
346 except it compares mtime entries instead of ctime entries.
347 .It Fl Fl newer-than Pa file
349 Only include files and directories newer than the specified file.
350 This compares ctime entries.
351 .It Fl Fl newer-mtime-than Pa file
355 except it compares mtime entries instead of ctime entries.
358 Honor the nodump file flag by skipping this file.
359 .It Fl Fl nopreserveHFSCompression
361 Mac OS X specific(v10.6 or later). Do not compress extracted regular files
362 which were compressed with HFS+ compression before archived.
363 By default, compress the regular files again with HFS+ compression.
369 Filenames or patterns are separated by null characters,
371 This is often used to read filenames output by the
375 .It Fl Fl no-same-owner
377 Do not extract owner and group IDs.
378 This is the reverse of
380 and the default behavior if
383 .It Fl Fl no-same-permissions
385 Do not extract full permissions (SGID, SUID, sticky bit, ACLs,
386 extended attributes or extended file flags).
387 This is the reverse of
389 and the default behavior if
392 .It Fl Fl numeric-owner
393 This is equivalent to
398 On extract, it causes user and group names in the archive
399 to be ignored in favor of the numeric user and group ids.
400 On create, it causes user and group names to not be stored
402 .It Fl O , Fl Fl to-stdout
404 In extract (-x) mode, files will be written to standard out rather than
405 being extracted to disk.
406 In list (-t) mode, the file listing will be written to stderr rather than
410 Use the user and group of the user running the program rather
411 than those specified in the archive.
412 Note that this has no significance unless
414 is specified, and the program is being run by the root user.
415 In this case, the file modes and flags from
416 the archive will be restored, but ACLs or owner information in
417 the archive will be discarded.
421 .Fl Fl format Ar ustar
422 .It Fl Fl older Ar date
424 Only include files and directories older than the specified date.
425 This compares ctime entries.
426 .It Fl Fl older-mtime Ar date
430 except it compares mtime entries instead of ctime entries.
431 .It Fl Fl older-than Pa file
433 Only include files and directories older than the specified file.
434 This compares ctime entries.
435 .It Fl Fl older-mtime-than Pa file
439 except it compares mtime entries instead of ctime entries.
440 .It Fl Fl one-file-system
442 Do not cross mount points.
443 .It Fl Fl options Ar options
444 Select optional behaviors for particular modules.
445 The argument is a text string containing comma-separated
447 These are passed to the modules that handle particular
448 formats to control how those formats will behave.
449 Each option has one of the following forms:
450 .Bl -tag -compact -width indent
452 The key will be set to the specified value in every module that supports it.
453 Modules that do not support this key will ignore it.
455 The key will be enabled in every module that supports it.
456 This is equivalent to
459 The key will be disabled in every module that supports it.
460 .It Ar module:key=value , Ar module:key , Ar module:!key
461 As above, but the corresponding key and value will be provided
462 only to modules whose name matches
465 The currently supported modules and keys are:
466 .Bl -tag -compact -width indent
467 .It Cm iso9660:joliet
468 Support Joliet extensions.
469 This is enabled by default, use
474 .It Cm iso9660:rockridge
475 Support Rock Ridge extensions.
476 This is enabled by default, use
479 .Cm iso9660:!rockridge
481 .It Cm gzip:compression-level
482 A decimal integer from 1 to 9 specifying the gzip compression level.
483 .It Cm gzip:timestamp
484 Store timestamp. This is enabled by default, use
489 .It Cm lrzip:compression Ns = Ns Ar type
492 as compression method.
493 Supported values are bzip2, gzip, lzo (ultra fast),
494 and zpaq (best, extremely slow).
495 .It Cm lrzip:compression-level
496 A decimal integer from 1 to 9 specifying the lrzip compression level.
497 .It Cm lzop:compression-level
498 A decimal integer from 1 to 9 specifying the lzop compression level.
499 .It Cm xz:compression-level
500 A decimal integer from 0 to 9 specifying the xz compression level.
501 .It Cm mtree: Ns Ar keyword
502 The mtree writer module allows you to specify which mtree keywords
503 will be included in the output.
504 Supported keywords include:
505 .Cm cksum , Cm device , Cm flags , Cm gid , Cm gname , Cm indent ,
506 .Cm link , Cm md5 , Cm mode , Cm nlink , Cm rmd160 , Cm sha1 , Cm sha256 ,
507 .Cm sha384 , Cm sha512 , Cm size , Cm time , Cm uid , Cm uname .
508 The default is equivalent to:
509 .Dq device, flags, gid, gname, link, mode, nlink, size, time, type, uid, uname .
511 Enables all of the above keywords.
514 to disable all keywords.
520 Produce human-readable output by indenting options and splitting lines
521 to fit into 80 columns.
522 .It Cm zip:compression Ns = Ns Ar type
525 as compression method.
526 Supported values are store (uncompressed) and deflate (gzip algorithm).
528 If a provided option is not supported by any module, that
530 .It Fl P , Fl Fl absolute-paths
532 By default, absolute pathnames (those that begin with a /
533 character) have the leading slash removed both when creating archives
534 and extracting from them.
537 will refuse to extract archive entries whose pathnames contain
539 or whose target directory would be altered by a symlink.
540 This option suppresses these behaviors.
541 .It Fl p , Fl Fl insecure , Fl Fl preserve-permissions
543 Preserve file permissions.
544 Attempt to restore the full permissions, including owner, file modes, file
545 flags and ACLs, if available, for each item extracted from the archive.
546 This is the default, if
548 is being run by root and can be overridden by also specifying
551 .Fl Fl no-same-permissions .
556 .It Fl q , Fl Fl fast-read
558 Extract or list only the first archive entry that matches each pattern
560 Exit as soon as each specified pattern or filename has been matched.
561 By default, the archive is always read to the very end, since
562 there can be multiple entries with the same name and, by convention,
563 later entries overwrite earlier entries.
564 This option is provided as a performance optimization.
567 Extract files as sparse files.
568 For every block on disk, check first if it contains only NULL bytes and seek
570 This works similar to the conv=sparse option of dd.
572 Modify file or archive member names according to
574 The pattern has the format
575 .Ar /old/new/ Ns Op ghHprRsS
578 is a basic regular expression,
580 is the replacement string of the matched part,
581 and the optional trailing letters modify
582 how the replacement is handled.
585 is not matched, the pattern is skipped.
588 ~ is substituted with the match, \e1 to \e9 with the content of
589 the corresponding captured group.
590 The optional trailing g specifies that matching should continue
591 after the matched part and stop on the first unmatched pattern.
592 The optional trailing s specifies that the pattern applies to the value
594 The optional trailing p specifies that after a successful substitution
595 the original path name and the new path name should be printed to
597 Optional trailing H, R, or S characters suppress substitutions
598 for hardlink targets, regular filenames, or symlink targets,
600 Optional trailing h, r, or s characters enable substitutions
601 for hardlink targets, regular filenames, or symlink targets,
605 which applies substitutions to all names.
606 In particular, it is never necessary to specify h, r, or s.
609 Extract owner and group IDs.
610 This is the reverse of
612 and the default behavior if
615 .It Fl Fl strip-components Ar count
616 Remove the specified number of leading path elements.
617 Pathnames with fewer elements will be silently skipped.
618 Note that the pathname is edited after checking inclusion/exclusion patterns
619 but before security checks.
620 .It Fl T Ar filename , Fl Fl files-from Ar filename
623 will read the list of names to be extracted from
627 will read names to be archived from
631 on a line by itself will cause the current directory to be changed to
632 the directory specified on the following line.
633 Names are terminated by newlines unless
638 also disables the special handling of lines containing
640 Note: If you are generating lists of files using
642 you probably want to use
647 After archiving all files, print a summary to stderr.
648 .It Fl U , Fl Fl unlink , Fl Fl unlink-first
650 Unlink files before creating them.
651 This can be a minor performance optimization if most files
652 already exist, but can make things slower if most files
653 do not already exist.
654 This flag also causes
656 to remove intervening directory symlinks instead of
658 See the SECURITY section below for more details.
660 Use the provided user id number and ignore the user
661 name from the archive.
664 is not also specified, the user name will be set to
666 .It Fl Fl uname Ar name
667 Use the provided user name.
668 On extract, this overrides the user name in the archive;
669 if the provided user name does not exist on the system,
670 it will be ignored and the user id
671 (from the archive or from the
674 will be used instead.
675 On create, this sets the user name that will be stored
677 the name is not verified against the system user database.
678 .It Fl Fl use-compress-program Ar program
679 Pipe the input (in x or t mode) or the output (in c mode) through
681 instead of using the builtin compression support.
682 .It Fl v , Fl Fl verbose
683 Produce verbose output.
684 In create and extract modes,
686 will list each file name as it is read from or written to
690 will produce output similar to that of
694 options will provide additional detail.
701 .It Fl w , Fl Fl confirmation , Fl Fl interactive
702 Ask for confirmation for every action.
703 .It Fl X Ar filename , Fl Fl exclude-from Ar filename
704 Read a list of exclusion patterns from the specified file.
707 for more information about the handling of exclusions.
710 Compress the resulting archive with
712 In extract or list modes, this option is ignored.
713 Note that, unlike other
715 implementations, this implementation recognizes bzip2 compression
716 automatically when reading archives.
717 .It Fl Z , Fl Fl compress , Fl Fl uncompress
719 Compress the resulting archive with
721 In extract or list modes, this option is ignored.
722 Note that, unlike other
724 implementations, this implementation recognizes compress compression
725 automatically when reading archives.
726 .It Fl z , Fl Fl gunzip , Fl Fl gzip
728 Compress the resulting archive with
730 In extract or list modes, this option is ignored.
731 Note that, unlike other
733 implementations, this implementation recognizes gzip compression
734 automatically when reading archives.
737 The following environment variables affect the execution of
739 .Bl -tag -width ".Ev BLOCKSIZE"
740 .It Ev TAR_READER_OPTIONS
741 The default options for format readers and compression readers.
744 option overrides this.
745 .It Ev TAR_WRITER_OPTIONS
746 The default options for format writers and compression writers.
749 option overrides this.
754 for more information.
759 option overrides this.
760 Please see the description of the
762 option above for more details.
764 The timezone to use when displaying dates.
767 for more information.
772 The following creates a new archive
775 that contains two files
779 .Dl Nm Fl czf Pa file.tar.gz Pa source.c Pa source.h
781 To view a detailed table of contents for this
783 .Dl Nm Fl tvf Pa file.tar.gz
785 To extract all entries from the archive on
786 the default tape drive:
789 To examine the contents of an ISO 9660 cdrom image:
790 .Dl Nm Fl tf Pa image.iso
792 To move file hierarchies, invoke
795 .Dl Nm Fl cf Pa - Fl C Pa srcdir\ . | Nm Fl xpf Pa - Fl C Pa destdir
796 or more traditionally
797 .Dl cd srcdir \&; Nm Fl cf Pa -\ . | ( cd destdir \&; Nm Fl xpf Pa - )
799 In create mode, the list of files and directories to be archived
800 can also include directory change instructions of the form
802 and archive inclusions of the form
803 .Cm @ Ns Pa archive-file .
804 For example, the command line
805 .Dl Nm Fl c Fl f Pa new.tar Pa foo1 Cm @ Ns Pa old.tgz Cm -C Ns Pa /tmp Pa foo2
806 will create a new archive
811 from the current directory and add it to the output archive.
812 It will then read each entry from
814 and add those entries to the output archive.
815 Finally, it will switch to the
819 to the output archive.
823 format can be used to create an output archive with arbitrary ownership,
824 permissions, or names that differ from existing data on disk:
826 .Dl $ cat input.mtree
828 .Dl usr/bin uid=0 gid=0 mode=0755 type=dir
829 .Dl usr/bin/ls uid=0 gid=0 mode=0755 type=file content=myls
830 .Dl $ tar -cvf output.tar @input.mtree
836 switches accept a variety of common date and time specifications, including
837 .Dq 12 Mar 2005 7:14:29pm ,
838 .Dq 2005-03-12 19:14 ,
841 .Dq 19:14 PST May 1 .
845 argument can be used to control various details of archive generation
847 For example, you can generate mtree output which only contains
852 .Dl Nm Fl cf Pa file.tar Fl Fl format=mtree Fl Fl options='!all,type,time,uid' Pa dir
853 or you can set the compression level used by gzip or xz compression:
854 .Dl Nm Fl czf Pa file.tar Fl Fl options='compression-level=9' .
855 For more details, see the explanation of the
856 .Fn archive_read_set_options
858 .Fn archive_write_set_options
859 API calls that are described in
862 .Xr archive_write 3 .
864 The bundled-arguments format is supported for compatibility
865 with historic implementations.
866 It consists of an initial word (with no leading - character) in which
867 each character indicates an option.
868 Arguments follow as separate words.
869 The order of the arguments must match the order
870 of the corresponding characters in the bundled command word.
872 .Dl Nm Cm tbf 32 Pa file.tar
873 specifies three flags
882 flags both require arguments,
883 so there must be two additional items
887 is the argument to the
891 is the argument to the
895 The mode options c, r, t, u, and x and the options
896 b, f, l, m, o, v, and w comply with SUSv2.
898 For maximum portability, scripts that invoke
900 should use the bundled-argument format above, should limit
915 Additional long options are provided to improve compatibility with other
918 Certain security issues are common to many archiving programs, including
920 In particular, carefully-crafted archives can request that
922 extract files to locations outside of the target directory.
923 This can potentially be used to cause unwitting users to overwrite
924 files they did not intend to overwrite.
925 If the archive is being extracted by the superuser, any file
926 on the system can potentially be overwritten.
927 There are three ways this can happen.
930 has mechanisms to protect against each one,
931 savvy users should be aware of the implications:
932 .Bl -bullet -width indent
934 Archive entries can have absolute pathnames.
939 character from filenames before restoring them to guard against this problem.
941 Archive entries can have pathnames that include
946 will not extract files containing
948 components in their pathname.
950 Archive entries can exploit symbolic links to restore
951 files to other directories.
952 An archive can restore a symbolic link to another directory,
953 then use that link to restore a file into that directory.
954 To guard against this,
956 checks each extracted path for symlinks.
957 If the final path element is a symlink, it will be removed
958 and replaced with the archive entry.
961 is specified, any intermediate symlink will also be unconditionally removed.
968 will refuse to extract the entry.
970 To protect yourself, you should be wary of any archives that
971 come from untrusted sources.
972 You should examine the contents of an archive with
973 .Dl Nm Fl tf Pa filename
977 option to ensure that
979 will not overwrite any existing files or the
981 option to remove any pre-existing files.
982 You should generally not extract archives while running with super-user
988 disables the security checks above and allows you to extract
989 an archive while preserving any absolute pathnames,
991 components, or symlinks to other directories.
1002 .Xr libarchive-formats 5 ,
1005 There is no current POSIX standard for the tar command; it appeared
1008 but was dropped from
1010 The options supported by this implementation were developed by surveying a
1011 number of existing tar implementations as well as the old POSIX specification
1012 for tar and the current POSIX specification for pax.
1014 The ustar and pax interchange file formats are defined by
1016 for the pax command.
1020 command appeared in Seventh Edition Unix, which was released in January, 1979.
1021 There have been numerous other implementations,
1022 many of which extended the file format.
1025 public-domain implementation (circa November, 1987)
1026 was quite influential, and formed the basis of GNU tar.
1027 GNU tar was included as the standard system tar
1033 This is a complete re-implementation based on the
1036 It was first released with
1040 This program follows
1042 for the definition of the
1045 Note that GNU tar prior to version 1.15 treated
1047 as a synonym for the
1048 .Fl Fl one-file-system
1053 option may differ from historic implementations.
1055 All archive output is written in correctly-sized blocks, even
1056 if the output is being compressed.
1057 Whether or not the last output block is padded to a full
1058 block size varies depending on the format and the
1060 For tar and cpio formats, the last block of output is padded
1061 to a full block size if the output is being
1062 written to standard output or to a character or block device such as
1064 If the output is being written to a regular file, the last block
1066 Many compressors, including
1070 complain about the null padding when decompressing an archive created by
1072 although they still extract it correctly.
1074 The compression and decompression is implemented internally, so
1075 there may be insignificant differences between the compressed output
1077 .Dl Nm Fl czf Pa - file
1078 and that generated by
1079 .Dl Nm Fl cf Pa - file | Nm gzip
1081 The default should be to read and write archives to the standard I/O paths,
1082 but tradition (and POSIX) dictates otherwise.
1088 modes require that the archive be uncompressed
1089 and located in a regular file on disk.
1090 Other archives can be modified using
1096 To archive a file called
1100 you must specify it as
1106 In create mode, a leading
1111 is stripped unless the
1113 option is specified.
1115 There needs to be better support for file selection on both create
1118 There is not yet any support for multi-volume archives or for archiving
1121 Converting between dissimilar archive formats (such as tar and cpio) using the
1123 convention can cause hard link information to be lost.
1124 (This is a consequence of the incompatible ways that different archive
1125 formats store hardlink information.)