tar.1 35 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180
  1. .\" This file is part of GNU tar. -*- nroff -*-
  2. .\" Copyright 2013-2014 Free Software Foundation, Inc.
  3. .\"
  4. .\" GNU tar is free software; you can redistribute it and/or modify
  5. .\" it under the terms of the GNU General Public License as published by
  6. .\" the Free Software Foundation; either version 3 of the License, or
  7. .\" (at your option) any later version.
  8. .\"
  9. .\" GNU tar is distributed in the hope that it will be useful,
  10. .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. .\" GNU General Public License for more details.
  13. .\"
  14. .\" You should have received a copy of the GNU General Public License
  15. .\" along with this program. If not, see <http://www.gnu.org/licenses/>.
  16. .TH TAR 1 "August 16, 2014" "TAR" "GNU TAR Manual"
  17. .SH NAME
  18. tar \- an archiving utility
  19. .SH SYNOPSIS
  20. .SS Traditional usage
  21. \fBtar\fR {\fBA\fR|\fBc\fR|\fBd\fR|\fBr\fR|\fBt\fR|\fBu\fR|\fBx\fR}\
  22. [\fBGnSkUWOmpsMBiajJzZhPlRvwo\fR] [\fIARG\fR...]
  23. .SS UNIX-style usage
  24. .sp
  25. \fBtar\fR \fB\-A\fR [\fIOPTIONS\fR] \fIARCHIVE\fR \fIARCHIVE\fR
  26. .sp
  27. \fBtar\fR \fB\-c\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  28. .sp
  29. \fBtar\fR \fB\-d\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  30. .sp
  31. \fBtar\fR \fB\-t\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIMEMBER\fR...]
  32. .sp
  33. \fBtar\fR \fB\-r\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  34. .sp
  35. \fBtar\fR \fB\-u\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  36. .sp
  37. \fBtar\fR \fB\-x\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIMEMBER\fR...]
  38. .SS GNU-style usage
  39. .sp
  40. \fBtar\fR {\fB\-\-catenate\fR|\fB\-\-concatenate} [\fIOPTIONS\fR] \fIARCHIVE\fR \fIARCHIVE\fR
  41. .sp
  42. \fBtar\fR \fB\-\-create\fR [\fB\-\-file\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  43. .sp
  44. \fBtar\fR {\fB\-\-diff\fR|\fB\-\-compare\fR} [\fB\-\-file\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  45. .sp
  46. \fBtar\fR \fB\-\-delete\fR [\fB\-\-file\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIMEMBER\fR...]
  47. .sp
  48. \fBtar\fR \fB\-\-append\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  49. .sp
  50. \fBtar\fR \fB\-\-list\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIMEMBER\fR...]
  51. .sp
  52. \fBtar\fR \fB\-\-test\-label\fR [\fB\-\-file\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fILABEL\fR...]
  53. .sp
  54. \fBtar\fR \fB\-\-update\fR [\fB\-\-file\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  55. .sp
  56. \fBtar\fR \fB\-\-update\fR [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIFILE\fR...]
  57. .sp
  58. \fBtar\fR {\fB\-\-extract\fR|\fB\-\-get\fR} [\fB\-f\fR \fIARCHIVE\fR] [\fIOPTIONS\fR] [\fIMEMBER\fR...]
  59. .SH NOTE
  60. This manpage is a short description of GNU \fBtar\fR. For a detailed
  61. discussion, including examples and usage recommendations, refer to the
  62. \fBGNU Tar Manual\fR available in texinfo format. If the \fBinfo\fR
  63. reader and the tar documentation are properly installed on your
  64. system, the command
  65. .PP
  66. .RS +4
  67. .B info tar
  68. .RE
  69. .PP
  70. should give you access to the complete manual.
  71. .PP
  72. You can also view the manual using the info mode in
  73. .BR emacs (1),
  74. or find it in various formats online at
  75. .PP
  76. .RS +4
  77. .B http://www.gnu.org/software/tar/manual
  78. .RE
  79. .PP
  80. If any discrepancies occur between this manpage and the
  81. \fBGNU Tar Manual\fR, the later shall be considered the authoritative
  82. source.
  83. .SH DESCRIPTION
  84. GNU
  85. .B tar
  86. is an archiving program designed to store multiple files in a single
  87. file (an \fBarchive\fR), and to manipulate such archives. The archive
  88. can be either a regular file or a device (e.g. a tape drive, hence the name
  89. of the program, which stands for \fBt\fRape \fBar\fRchiver), which can
  90. be located either on the local or on a remote machine.
  91. .PP
  92. .SS Option styles
  93. Options to GNU \fBtar\fR can be given in three different styles.
  94. In
  95. .BR "traditional style" ,
  96. the first argument is a cluster of option letters and all subsequent
  97. arguments supply arguments to those options that require them. The
  98. arguments are read in the same order as the option letters. Any
  99. command line words that remain after all options has been processed
  100. are treated as non-optional arguments: file or archive member names.
  101. .PP
  102. For example, the \fBc\fR option requires creating the archive, the
  103. \fBv\fR option requests the verbose operation, and the \fBf\fR option
  104. takes an argument that sets the name of the archive to operate upon.
  105. The following command, written in the traditional style, instructs tar
  106. to store all files from the directory
  107. .B /etc
  108. into the archive file
  109. .B etc.tar
  110. verbosely listing the files being archived:
  111. .PP
  112. .EX
  113. .B tar cfv a.tar /etc
  114. .EE
  115. .PP
  116. In
  117. .BR "UNIX " or " short-option style" ,
  118. each option letter is prefixed with a single dash, as in other command
  119. line utilities. If an option takes argument, the argument follows it,
  120. either as a separate command line word, or immediately following the
  121. option. However, if the option takes an \fBoptional\fR argument, the
  122. argument must follow the option letter without any intervening
  123. whitespace, as in \fB\-g/tmp/snar.db\fR.
  124. .PP
  125. Any number of options not taking arguments can be
  126. clustered together after a single dash, e.g. \fB\-vkp\fR. Options
  127. that take arguments (whether mandatory or optional), can appear at
  128. the end of such a cluster, e.g. \fB\-vkpf a.tar\fR.
  129. .PP
  130. The example command above written in the
  131. .B short-option style
  132. could look like:
  133. .PP
  134. .EX
  135. .B tar -cvf a.tar /etc
  136. or
  137. .B tar -c -v -f a.tar /etc
  138. .EE
  139. .PP
  140. In
  141. .BR "GNU " or " long-option style" ,
  142. each option begins with two dashes and has a meaningful name,
  143. consisting of lower-case letters and dashes. When used, the long
  144. option can be abbreviated to its initial letters, provided that
  145. this does not create ambiguity. Arguments to long options are
  146. supplied either as a separate command line word, immediately following
  147. the option, or separated from the option by an equals sign with no
  148. intervening whitespace. Optional arguments must always use the latter
  149. method.
  150. .PP
  151. Here are several ways of writing the example command in this style:
  152. .PP
  153. .EX
  154. .B tar --create --file a.tar --verbose /etc
  155. .EE
  156. or (abbreviating some options):
  157. .EX
  158. .B tar --cre --file=a.tar --verb /etc
  159. .EE
  160. .PP
  161. The options in all three styles can be intermixed, although doing so
  162. with old options is not encouraged.
  163. .SS Operation mode
  164. The options listed in the table below tell GNU \fBtar\fR what
  165. operation it is to perform. Exactly one of them must be given.
  166. Meaning of non-optional arguments depends on the operation mode
  167. requested.
  168. .TP
  169. \fB\-A\fR, \fB\-\-catenate\fR, \fB\-\-concatenate\fR
  170. Append archive to the end of another archive. The arguments are
  171. treated as the names of archives to append. All archives must be of
  172. the same format as the archive they are appended to, otherwise the
  173. resulting archive might be unusable with non-GNU implementations of
  174. \fBtar\fR. Notice also that when more than one archive is given, the
  175. members from archives other than the first one will be accessible in
  176. the resulting archive only if using the \fB\-i\fR
  177. (\fB\-\-ignore\-zeros) option.
  178. Compressed archives cannot be concatenated.
  179. .TP
  180. \fB\-c\fR, \fB\-\-create\fR
  181. Create a new archive. Arguments supply the names of the files to be
  182. archived. Directories are archived recursively, unless the
  183. \fB\-\-no\-recursion\fR option is given.
  184. .TP
  185. \fB\-d\fR, \fB\-\-diff\fR, \fB\-\-compare\fR
  186. Find differences between archive and file system. The arguments are
  187. optional and specify archive members to compare. If not given, the
  188. current working directory is assumed.
  189. .TP
  190. \fB\-\-delete\fR
  191. Delete from the archive. The arguments supply names of the archive
  192. members to be removed. At least one argument must be given.
  193. This option does not operate on compressed archives. There is no
  194. short option equivalent.
  195. .TP
  196. \fB\-r\fR, \fB\-\-append\fR
  197. Append files to the end of an archive. Arguments have the same
  198. meaning as for \fB\-c\fR (\fB\-\-create).
  199. .TP
  200. \fB\-t\fR, \fB\-\-list\fR
  201. List the contents of an archive. Arguments are optional. When given,
  202. they specify the names of the members to list.
  203. .TP
  204. \fB\-\-test\-label
  205. Test the archive volume label and exit. When used without arguments,
  206. it prints the volume label (if any) and exits with status \fB0\fR.
  207. When one or more command line arguments are given.
  208. .B tar
  209. compares the volume label with each argument. It exits with code
  210. \fB0\fR if a match is found, and with code \fB1\fR otherwise. No
  211. output is displayed, unless used together with the \fB\-v\fR
  212. (\fB\-\-verbose\fR) option.
  213. There is no short option equivalent for this option.
  214. .TP
  215. \fB\-u\fR, \fB\-\-update\fR
  216. Append files which are newer than the corresponding copy in the
  217. archive. Arguments have the same meaning as with \fB\-c\fR and
  218. \fB\-r\fR options.
  219. .TP
  220. \fB\-x\fR, \fB\-\-extract\fR, \fB\-\-get\fR
  221. Extract files from an archive. Arguments are optional. When given,
  222. they specify names of the archive members to be extracted.
  223. .TP
  224. .TP
  225. \fB\-\-show\-defaults\fR
  226. Show built-in defaults for various \fBtar\fR options and exit. No
  227. arguments are allowed.
  228. .TP
  229. \fB\-?\fR, \fB\-\-help
  230. Display a short option summary and exit. No arguments allowed.
  231. .TP
  232. \fB\-\-usage\fR
  233. Display a list of available options and exit. No arguments allowed.
  234. .TP
  235. \fB\-\-version\fR
  236. Print program version and copyright information and exit.
  237. .SH OPTIONS
  238. .SS Operation modifiers
  239. .TP
  240. \fB\-\-check\-device\fR
  241. Check device numbers when creating incremental archives (default).
  242. .TP
  243. \fB\-g\fR, \fB\-\-listed\-incremental\fR=\fIFILE\fR
  244. Handle new GNU-format incremental backups. \fIFILE\fR is the name of
  245. a \fBsnapshot file\fR, where tar stores additional information which
  246. is used to decide which files changed since the previous incremental
  247. dump and, consequently, must be dumped again. If \fIFILE\fR does not
  248. exist when creating an archive, it will be created and all files will
  249. be added to the resulting archive (the \fBlevel 0\fR dump). To create
  250. incremental archives of non-zero level \fBN\fR, create a copy of the
  251. snapshot file created during the level \fBN-1\fR, and use it as
  252. \fIFILE\fR.
  253. When listing or extracting, the actual contents of \fIFILE\fR is not
  254. inspected, it is needed only due to syntactical requirements. It is
  255. therefore common practice to use \fB/dev/null\fR in its place.
  256. .TP
  257. \fB\-G\fR, \fB\-\-incremental\fR
  258. Handle old GNU-format incremental backups.
  259. .TP
  260. \fB\-\-ignore\-failed\-read\fR
  261. Do not exit with nonzero on unreadable files.
  262. .TP
  263. \fB\-\-level\fR=\fINUMBER\fR
  264. Set dump level for created listed-incremental archive. Currently only
  265. \fB\-\-level=0\fR is meaningful: it instructs \fBtar\fR to truncate
  266. the snapshot file before dumping, thereby forcing a level 0 dump.
  267. .TP
  268. \fB\-n\fR, \fB\-\-seek\fR
  269. Assume the archive is seekable. Normally \fBtar\fR determines
  270. automatically whether the archive can be seeked or not. This option
  271. is intended for use in cases when such recognition fails. It takes
  272. effect only if the archive is open for reading (e.g. with
  273. .B \-\-list
  274. or
  275. .B \-\-extract
  276. options).
  277. .TP
  278. \fB\-\-no\-check\-device\fR
  279. Do not check device numbers when creating incremental archives.
  280. .TP
  281. \fB\-\-no\-seek\fR
  282. Assume the archive is not seekable.
  283. .TP
  284. \fB\-\-occurrence\fR[=\fIN\fR]
  285. Process only the \fIN\fRth occurrence of each file in the
  286. archive. This option is valid only when used with one of the
  287. following subcommands: \fB\-\-delete\fR, \fB\-\-diff\fR,
  288. \fB\-\-extract\fR or \fB\-\-list\fR and when a list of files is given
  289. either on the command line or via the \fB\-\fRT option. The default
  290. \fIN\fR is \fB1\fR.
  291. .TP
  292. \fB\-\-restrict\fR
  293. Disable the use of some potentially harmful options.
  294. .TP
  295. \fB\-\-sparse\-version\fR=\fIMAJOR\fR[.\fIMINOR\fR]
  296. Set version of the sparse format to use (implies \fB\-\-sparse\fR).
  297. This option implies
  298. .BR \-\-sparse .
  299. Valid argument values are
  300. .BR 0.0 ,
  301. .BR 0.1 ", and"
  302. .BR 1.0 .
  303. For a detailed discussion of sparse formats, refer to the \fBGNU Tar
  304. Manual\fR, appendix \fBD\fR, "\fBSparse Formats\fR". Using \fBinfo\fR
  305. reader, it can be accessed running the following command:
  306. .BR "info tar 'Sparse Formats'" .
  307. .TP
  308. \fB\-S\fR, \fB\-\-sparse\fR
  309. Handle sparse files efficiently. Some files in the file system may
  310. have segments which were actually never written (quite often these are
  311. database files created by such systems as \fBDBM\fR). When given this
  312. option, \fBtar\fR attempts to determine if the file is sparse prior to
  313. archiving it, and if so, to reduce the resulting archive size by not
  314. dumping empty parts of the file.
  315. .SS Overwrite control
  316. These options control \fBtar\fR actions when extracting a file over
  317. an existing copy on disk.
  318. .TP
  319. \fB\-k\fR, \fB\-\-keep\-old\-files\fR
  320. Don't replace existing files when extracting.
  321. .TP
  322. \fB\-\-keep\-newer\-files\fR
  323. Don't replace existing files that are newer than their archive copies.
  324. .TP
  325. \fB\-\-no\-overwrite\-dir\fR
  326. Preserve metadata of existing directories.
  327. .TP
  328. \fB\-\-one\-top\-level\fR[\fB=\fIDIR\fR]
  329. Extract all files into \fIDIR\fR, or, if used without argument, into a
  330. subdirectory named by the base name of the archive (minus standard
  331. compression suffixes recognizable by \fB\-\-auto\-compress).
  332. .TP
  333. \fB\-\-overwrite\fR
  334. Overwrite existing files when extracting.
  335. .TP
  336. \fB\-\-overwrite\-dir\fR
  337. Overwrite metadata of existing directories when extracting (default).
  338. .TP
  339. \fB\-\-recursive\-unlink\fR
  340. Recursively remove all files in the directory prior to extracting it.
  341. .TP
  342. \fB\-\-remove\-files\fR
  343. Remove files from disk after adding them to the archive.
  344. .TP
  345. \fB\-\-skip\-old\-files
  346. Don't replace existing files when extracting, silently skip over them.
  347. .TP
  348. \fB\-U\fR, \fB\-\-unlink\-first\fR
  349. Remove each file prior to extracting over it.
  350. .TP
  351. \fB\-W\fR, \fB\-\-verify\fR
  352. Verify the archive after writing it.
  353. .SS Output stream selection
  354. .TP
  355. \fB\-\-ignore\-command\-error\fR
  356. .TP
  357. Ignore subprocess exit codes.
  358. .TP
  359. \fB\-\-no\-ignore\-command\-error\fR
  360. Treat non-zero exit codes of children as error (default).
  361. .TP
  362. \fB\-O\fR, \fB\-\-to\-stdout\fR
  363. Extract files to standard output.
  364. .TP
  365. \fB\-\-to\-command\fR=\fICOMMAND\fR
  366. Pipe extracted files to \fICOMMAND\fR. The argument is the pathname
  367. of an external program, optionally with command line arguments. The
  368. program will be invoked and the contents of the file being extracted
  369. supplied to it on its standard output. Additional data will be
  370. supplied via the following environment variables:
  371. .RS
  372. .TP
  373. .B TAR_FILETYPE
  374. Type of the file. It is a single letter with the following meaning:
  375. .sp
  376. .nf
  377. .ta 8n 20n
  378. f Regular file
  379. d Directory
  380. l Symbolic link
  381. h Hard link
  382. b Block device
  383. c Character device
  384. .fi
  385. Currently only regular files are supported.
  386. .TP
  387. .B TAR_MODE
  388. File mode, an octal number.
  389. .TP
  390. .B TAR_FILENAME
  391. The name of the file.
  392. .TP
  393. .B TAR_REALNAME
  394. Name of the file as stored in the archive.
  395. .TP
  396. .B TAR_UNAME
  397. Name of the file owner.
  398. .TP
  399. .B TAR_GNAME
  400. Name of the file owner group.
  401. .TP
  402. .B TAR_ATIME
  403. Time of last access. It is a decimal number, representing seconds
  404. since the Epoch. If the archive provides times with nanosecond
  405. precision, the nanoseconds are appended to the timestamp after a
  406. decimal point.
  407. .TP
  408. .B TAR_MTIME
  409. Time of last modification.
  410. .TP
  411. .B TAR_CTIME
  412. Time of last status change.
  413. .TP
  414. .B TAR_SIZE
  415. Size of the file.
  416. .TP
  417. .B TAR_UID
  418. UID of the file owner.
  419. .TP
  420. .B TAR_GID
  421. GID of the file owner.
  422. .RE
  423. .RS
  424. Additionally, the following variables contain information about
  425. \fBtar\fR operation mode and the archive being processed:
  426. .TP
  427. .B TAR_VERSION
  428. GNU \fBtar\fR version number.
  429. .TP
  430. .B TAR_ARCHIVE
  431. The name of the archive \fBtar\fR is processing.
  432. .TP
  433. .B TAR_BLOCKING_FACTOR
  434. Current blocking factor, i.e. number of 512-byte blocks in a record.
  435. .TP
  436. .B TAR_VOLUME
  437. Ordinal number of the volume \fBtar\fR is processing (set if
  438. reading a multi-volume archive).
  439. .TP
  440. .B TAR_FORMAT
  441. Format of the archive being processed. One of:
  442. .BR gnu ,
  443. .BR oldgnu ,
  444. .BR posix ,
  445. .BR ustar ,
  446. .BR v7 .
  447. .B TAR_SUBCOMMAND
  448. A short option (with a leading dash) describing the operation \fBtar\fR is
  449. executing.
  450. .RE
  451. .SS Handling of file attributes
  452. .TP
  453. \fB\-\-atime\-preserve\fR[=\fIMETHOD\fR]
  454. Preserve access times on dumped files, either by restoring the times
  455. after reading (\fIMETHOD\fR=\fBreplace\fR, this is the default) or by
  456. not setting the times in the first place (\fIMETHOD\fR=\fBsystem\fR)
  457. .TP
  458. \fB\-\-delay\-directory\-restore\fR
  459. Delay setting modification times and permissions of extracted
  460. directories until the end of extraction. Use this option when
  461. extracting from an archive which has unusual member ordering.
  462. .TP
  463. \fB\-\-group\fR=\fINAME\fR
  464. Force \fINAME\fR as group for added files.
  465. .TP
  466. \fB\-\-mode\fR=\fICHANGES\fR
  467. Force symbolic mode \fICHANGES\fR for added files.
  468. .TP
  469. \fB\-\-mtime\fR=\fIDATE-OR-FILE\fR
  470. Set mtime for added files. \fIDATE-OR-FILE\fR is either a date/time
  471. in almost arbitrary formate, or the name of an existing file. In the
  472. latter case the mtime of that file will be used.
  473. .TP
  474. \fB\-m\fR, \fB\-\-touch\fR
  475. Don't extract file modified time.
  476. .TP
  477. \fB\-\-no\-delay\-directory\-restore\fR
  478. Cancel the effect of the prior \fB\-\-delay\-directory\-restore\fR option.
  479. .TP
  480. \fB\-\-no\-same\-owner\fR
  481. Extract files as yourself (default for ordinary users).
  482. .TP
  483. \fB\-\-no\-same\-permissions\fR
  484. Apply the user's umask when extracting permissions from the archive
  485. (default for ordinary users).
  486. .TP
  487. \fB\-\-numeric\-owner\fR
  488. Always use numbers for user/group names.
  489. .TP
  490. \fB\-\-owner\fR=\fINAME\fR
  491. Force \fINAME\fR as owner for added files.
  492. .TP
  493. \fB\-p\fR, \fB\-\-preserve\-permissions\fR, \fB\-\-same\-permissions\fR
  494. extract information about file permissions (default for superuser)
  495. .TP
  496. \fB\-\-preserve\fR
  497. Same as both \fB\-p\fR and \fB\-s\fR.
  498. .TP
  499. \fB\-\-same\-owner\fR
  500. Try extracting files with the same ownership as exists in the archive
  501. (default for superuser).
  502. .TP
  503. \fB\-s\fR, \fB\-\-preserve\-order\fR, \fB\-\-same\-order\fR
  504. Sort names to extract to match archive
  505. .TP
  506. \fB\-\-sort=\fIORDER\fR
  507. When creating an archive, sort directory entries according to
  508. \fIORDER\fR, which is one of
  509. .BR none ,
  510. .BR name ", or"
  511. .BR inode .
  512. The default is \fB\-\-sort=none\fR, which stores archive members in
  513. the same order as returned by the operating system.
  514. Using \fB\-\-sort=name\fR ensures the member ordering in the created archive
  515. is uniform and reproducible.
  516. Using \fB\-\-sort=inode\fR reduces the number of disk seeks made when
  517. creating the archive and thus can considerably speed up archivation.
  518. This sorting order is supported only if the underlying system provides
  519. the necessary information.
  520. .SS Device selection and switching
  521. .TP
  522. \fB\-f\fR, \fB\-\-file\fR=\fIARCHIVE\fR
  523. Use archive file or device \fIARCHIVE\fR. If this option is not
  524. given, \fBtar\fR will first examine the environment variable `TAPE'.
  525. If it is set, its value will be used as the archive name. Otherwise,
  526. \fBtar\fR will assume the compiled-in default. The default
  527. value can be inspected either using the
  528. .B \-\-show\-defaults
  529. option, or at the end of the \fBtar \-\-help\fR output.
  530. An archive name that has a colon in it specifies a file or device on a
  531. remote machine. The part before the colon is taken as the machine
  532. name or IP address, and the part after it as the file or device
  533. pathname, e.g.:
  534. .EX
  535. --file=remotehost:/dev/sr0
  536. .EE
  537. An optional username can be prefixed to the hostname, placing a \fB@\fR
  538. sign between them.
  539. By default, the remote host is accessed via the
  540. .BR rsh (1)
  541. command. Nowadays it is common to use
  542. .BR ssh (1)
  543. instead. You can do so by giving the following command line option:
  544. .EX
  545. --rsh-command=/usr/bin/ssh
  546. .EE
  547. The remote mashine should have the
  548. .BR rmt (8)
  549. command installed. If its pathname does not match \fBtar\fR's
  550. default, you can inform \fBtar\fR about the correct pathname using the
  551. .B \-\-rmt\-command
  552. option.
  553. .TP
  554. \fB\-\-force\-local\fR
  555. Archive file is local even if it has a colon.
  556. .TP
  557. \fB\-\fRF, \fB\-\-info\-script\fR=\fICOMMAND\fR, \fB\-\-new\-volume\-script\fR=\fICOMMAND\fR
  558. Run \fICOMMAND\fR at the end of each tape (implies \fB\-M\fR). The
  559. command can include arguments. When started, it will inherit \fBtar\fR's
  560. environment plus the following variables:
  561. .RS
  562. .TP
  563. .B TAR_VERSION
  564. GNU \fBtar\fR version number.
  565. .TP
  566. .B TAR_ARCHIVE
  567. The name of the archive \fBtar\fR is processing.
  568. .TP
  569. .B TAR_BLOCKING_FACTOR
  570. Current blocking factor, i.e. number of 512-byte blocks in a record.
  571. .TP
  572. .B TAR_VOLUME
  573. Ordinal number of the volume \fBtar\fR is processing (set if
  574. reading a multi-volume archive).
  575. .TP
  576. .B TAR_FORMAT
  577. Format of the archive being processed. One of:
  578. .BR gnu ,
  579. .BR oldgnu ,
  580. .BR posix ,
  581. .BR ustar ,
  582. .BR v7 .
  583. .TP
  584. .B TAR_SUBCOMMAND
  585. A short option (with a leading dash) describing the operation \fBtar\fR is
  586. executing.
  587. .TP
  588. .B TAR_FD
  589. File descriptor which can be used to communicate the new volume name
  590. to
  591. .BR tar .
  592. .RE
  593. .RS
  594. If the info script fails, \fBtar\fR exits; otherwise, it begins writing
  595. the next volume.
  596. .RE
  597. .TP
  598. \fB\-L\fR, \fB\-\-tape\-length\fR=\fN\fR
  599. Change tape after writing \fIN\fRx1024 bytes. If \fIN\fR is followed
  600. by a size suffix (see the subsection
  601. .B Size suffixes
  602. below), the suffix specifies the multiplicative factor to be used
  603. instead of 1024.
  604. This option implies
  605. .BR \-M .
  606. .TP
  607. \fB\-M\fR, \fB\-\-multi\-volume\fR
  608. Create/list/extract multi-volume archive.
  609. .TP
  610. \fB\-\-rmt\-command\fR=\fICOMMAND\fR
  611. Use \fICOMMAND\fR instead of \fBrmt\fR when accessing remote
  612. archives. See the description of the
  613. .B \-f
  614. option, above.
  615. .TP
  616. \fB\-\-rsh\-command\fR=\fICOMMAND\fR
  617. Use \fICOMMAND\fR instead of \fBrsh\fR when accessing remote
  618. archives. See the description of the
  619. .B \-f
  620. option, above.
  621. .TP
  622. \fB\-\-volno\-file\fR=\fIFILE\fR
  623. When this option is used in conjunction with
  624. .BR \-\-multi\-volume ,
  625. .B tar
  626. will keep track of which volume of a multi-volume archive it is
  627. working in \fIFILE\fR.
  628. .SS Device blocking
  629. .TP
  630. \fB\-b\fR, \fB\-\-blocking\-factor\fR=\fIBLOCKS\fR
  631. Set record size to \fIBLOCKS\fRx\fB512\fR bytes.
  632. .TP
  633. \fB\-B\fR, \fB\-\-read\-full\-records\fR
  634. When listing or extracting, accept incomplete input records after
  635. end-of-file marker.
  636. .TP
  637. \fB\-i\fR, \fB\-\-ignore\-zeros\fR
  638. Ignore zeroed blocks in archive. Normally two consecutive 512-blocks
  639. filled with zeroes mean EOF and tar stops reading after encountering
  640. them. This option instructs it to read further and is useful when
  641. reading archives created with the \fB\-A\fR option.
  642. .TP
  643. \fB\-\-record\-size\fR=\fINUMBER\fR
  644. Set record size. \fINUMBER\fR is the number of bytes per record. It
  645. must be multiple of \fB512\fR. It can can be suffixed with a \fBsize
  646. suffix\fR, e.g. \fB\-\-record-size=10K\fR, for 10 Kilobytes. See the
  647. subsection
  648. .BR "Size suffixes" ,
  649. for a list of valid suffixes.
  650. .SS Archive format selection
  651. .TP
  652. \fB\-H\fR, \fB\-\-format\fR=\fIFORMAT\fR
  653. Create archive of the given format. Valid formats are:
  654. .RS
  655. .TP
  656. .B gnu
  657. GNU tar 1.13.x format
  658. .TP
  659. .B oldgnu
  660. GNU format as per tar <= 1.12.
  661. .TP
  662. \fBpax\fR, \fBposix\fR
  663. POSIX 1003.1-2001 (pax) format.
  664. .TP
  665. .B ustar
  666. POSIX 1003.1-1988 (ustar) format.
  667. .TP
  668. .B v7
  669. Old V7 tar format.
  670. .RE
  671. .TP
  672. \fB\-\-old\-archive\fR, \fB\-\-portability\fR
  673. Same as \fB\-\-format=v7\fR.
  674. .TP
  675. \fB\-\-pax\-option\fR=\fIkeyword\fR[[:]=\fIvalue\fR][,\fIkeyword\fR[[:]=\fIvalue\fR]]...
  676. Control pax keywords when creating \fBPAX\fR archives (\fB\-H
  677. pax\fR). This option is equivalent to the \fB\-o\fR option of the
  678. .BR pax (1) utility.
  679. .TP
  680. \fB\-\-posix\fR
  681. Same as \fB\-\-format=posix\fR.
  682. .TP
  683. \fB\-V\fR, \fB\-\-label\fR=\fITEXT\fR
  684. Create archive with volume name \fITEXT\fR. If listing or extracting,
  685. use \fITEXT\fR as a globbing pattern for volume name.
  686. .SS Compression options
  687. .TP
  688. \fB\-a\fR, \fB\-\-auto\-compress\fR
  689. Use archive suffix to determine the compression program.
  690. .TP
  691. \fB\-\fRI, \fB\-\-use\-compress\-program\fI=\fICOMMAND\fR
  692. Filter data through \fICOMMAND\fR. It must accept the \fB\-d\fR
  693. option, for decompression. The argument can contain command line
  694. options.
  695. .TP
  696. \fB\-j\fR, \fB\-\-bzip2\fR
  697. Filter the archive through
  698. .BR bzip2 (1).
  699. .TP
  700. \fB\-J\fR, \fB\-\-xz\fR
  701. Filter the archive through
  702. .BR xz (1).
  703. .TP
  704. \fB\-\-lzip\fR
  705. Filter the archive through
  706. .BR lzip (1).
  707. .TP
  708. \fB\-\-lzma\fR
  709. Filter the archive through
  710. .BR lzma (1).
  711. .TP
  712. \fB\-\-lzop\fR
  713. Filter the archive through
  714. .BR lzop (1).
  715. .TP
  716. \fB\-\-no\-auto\-compress\fR
  717. Do not use archive suffix to determine the compression program.
  718. .TP
  719. \fB\-z\fR, \fB\-\-gzip\fR, \fB\-\-gunzip\fR, \fB\-\-ungzip\fR
  720. Filter the archive through
  721. .BR gzip (1).
  722. .TP
  723. \fB\-\fRZ, \fB\-\-compress\fR, \fB\-\-uncompress\fR
  724. Filter the archive through
  725. .BR compress (1).
  726. .SS Local file selection
  727. .TP
  728. \fB\-\-add\-file\fR=\fIFILE\fR
  729. Add \fIFILE\fR to the archive (useful if its name starts with a dash).
  730. .TP
  731. \fB\-\-backup\fR[=\fICONTROL\fR]
  732. Backup before removal. The \fICONTROL\fR argument, if supplied,
  733. controls the backup policy. Its valid values are:
  734. .RS
  735. .TP
  736. .BR none ", " off
  737. Never make backups.
  738. .TP
  739. .BR t ", " numbered
  740. Make numbered backups.
  741. .TP
  742. .BR nil ", " existing
  743. Make numbered backups if numbered backups exist, simple backups otherwise.
  744. .TP
  745. .BR never ", " simple
  746. Always make simple backups
  747. .RS
  748. .RE
  749. If \fICONTROL\fR is not given, the value is taken from the
  750. .B VERSION_CONTROL
  751. environment variable. If it is not set, \fBexisting\fR is assumed.
  752. .RE
  753. .TP
  754. \fB\-C\fR, \fB\-\-directory\fR=\fIDIR\fR
  755. Change to directory DIR.
  756. .TP
  757. \fB\-\-exclude\fR=\fIPATTERN\fR
  758. Exclude files matching \fIPATTERN\fR, a
  759. .BR glob (3)-style
  760. wildcard pattern.
  761. .TP
  762. \fB\-\-exclude\-backups\fR
  763. Exclude backup and lock files.
  764. .TP
  765. \fB\-\-exclude\-caches\fR
  766. Exclude contents of directories containing file \fBCACHEDIR.TAG\fR,
  767. except for the tag file itself.
  768. .TP
  769. \fB\-\-exclude\-caches\-all\fR
  770. Exclude directories containing file \fBCACHEDIR.TAG\fR and the file itself.
  771. .TP
  772. \fB\-\-exclude\-caches\-under\fR
  773. Exclude everything under directories containing \fBCACHEDIR.TAG\fR
  774. .TP
  775. \fB\-\-exclude\-ignore=\fIFILE\fR
  776. Before dumping a directory, see if it contains \fIFILE\fR.
  777. If so, read exclusion patterns from this file. The patterns affect
  778. only the directory itself.
  779. .TP
  780. \fB\-\-exclude\-ignore\-recursive=\fIFILE\fR
  781. Same as \fB\-\-exclude\-ignore\fR, except that patterns from
  782. \fIFILE\fR affect both the directory and all its subdirectories.
  783. .TP
  784. \fB\-\-exclude\-tag\fR=\fIFILE\fR
  785. Exclude contents of directories containing \fIFILE\fR, except for
  786. \fIFILE\fR itself.
  787. .TP
  788. \fB\-\-exclude\-tag\-all\fR=\fIFILE\fR
  789. Exclude directories containing \fIFILE\fR.
  790. .TP
  791. \fB\-\-exclude\-tag\-under\fR=\fIFILE\fR
  792. Exclude everything under directories containing \fIFILE\fR.
  793. .TP
  794. \fB\-\-exclude\-vcs\fR
  795. Exclude version control system directories.
  796. .TP
  797. \fB\-\-exclude\-vcs\-ignores\fR
  798. Exclude files that match patterns read from VCS-specific ignore
  799. files. Supported files are:
  800. .BR .cvsignore ,
  801. .BR .gitignore ,
  802. .BR .bzrignore ", and"
  803. .BR .hgignore .
  804. .TP
  805. \fB\-h\fR, \fB\-\-dereference\fR
  806. Follow symlinks; archive and dump the files they point to.
  807. .TP
  808. \fB\-\-hard\-dereference\fR
  809. Follow hard links; archive and dump the files they refer to.
  810. .TP
  811. \fB\-K\fR, \fB\-\-starting\-file\fR=\fIMEMBER\fR
  812. Begin at the given member in the archive.
  813. .TP
  814. \fB\-\-newer\-mtime\fR=\fIDATE\fR
  815. Work on files whose data changed after the \fIDATE\fR. If \fIDATE\fR
  816. starts with \fB/\fR or \fB.\fR it is taken to be a file name; the
  817. mtime of that file is used as the date.
  818. .TP
  819. \fB\-\-no\-null\fR
  820. Disable the effect of the previous \fB\-\-null\fR option.
  821. .TP
  822. \fB\-\-no\-recursion\fR
  823. Avoid descending automatically in directories.
  824. .TP
  825. \fB\-\-no\-unquote\fR
  826. Do not unquote input file or member names.
  827. .TP
  828. \fB\-\-null\fR
  829. Instruct subsequent \fB\-T\fR options to read null-terminated names,
  830. disable handling of the \fB\-C\fR option read from the file.
  831. .TP
  832. \fB\-N\fR, \fB\-\-newer\fR=\fIDATE\fR, \fB\-\-after\-date\fR=\fIDATE\fR
  833. Only store files newer than DATE. If \fIDATE\fR starts with \fB/\fR
  834. or \fB.\fR it is taken to be a file name; the ctime of that file is
  835. used as the date.
  836. .TP
  837. \fB\-\-one\-file\-system\fR
  838. Stay in local file system when creating archive.
  839. .TP
  840. \fB\-P\fR, \fB\-\-absolute\-names\fR
  841. Don't strip leading slashes from file names when creating archives.
  842. .TP
  843. \fB\-\-recursion\fR
  844. Recurse into directories (default).
  845. .TP
  846. \fB\-\-suffix\fR=\fISTRING\fR
  847. Backup before removal, override usual suffix. Default suffix is \fB~\fR,
  848. unless overridden by environment variable \fBSIMPLE_BACKUP_SUFFIX\fR.
  849. .TP
  850. \fB\-T\fR, \fB\-\-files\-from\fR=\fIFILE\fR
  851. Get names to extract or create from \fIFILE\fR.
  852. .TP
  853. \fB\-\-unquote\fR
  854. Unquote file or member names (default).
  855. .TP
  856. \fB\-X\fR, \fB\-\-exclude\-from\fR=\fIFILE\fR
  857. Exclude files matching patterns listed in FILE.
  858. .SS File name transformations
  859. .TP
  860. \fB\-\-strip\-components\fR=\fINUMBER\fR
  861. Strip \fINUMBER\fR leading components from file names on extraction.
  862. .TP
  863. \fB\-\-transform\fR=\fIEXPRESSION\dR, \fB\-\-xform\fR=\fIEXPRESSION\fR
  864. Use sed replace \fIEXPRESSION\fR to transform file names.
  865. .SS File name matching options
  866. These options affect both exclude and include patterns.
  867. .TP
  868. \fB\-\-anchored\fR
  869. Patterns match file name start.
  870. .TP
  871. \fB\-\-ignore\-case\fR
  872. Ignore case.
  873. .TP
  874. \fB\-\-no\-anchored\fR
  875. Patterns match after any \fB/\fR (default for exclusion).
  876. .TP
  877. \fB\-\-no\-ignore\-case\fR
  878. Case sensitive matching (default).
  879. .TP
  880. \fB\-\-no\-wildcards\fR
  881. Verbatim string matching.
  882. .TP
  883. \fB\-\-no\-wildcards\-match\-slash\fR
  884. Wildcards do not match \fB/\fR.
  885. .TP
  886. \fB\-\-wildcards\fR
  887. Use wildcards (default for exclusion).
  888. .TP
  889. \fB\-\-wildcards\-match\-slash\fR
  890. Wildcards match \fB/\fR (default for exclusion).
  891. .SS Informative output
  892. .TP
  893. \fB\-\-checkpoint\fR[=\fIN\fR]
  894. Display progress messages every \fIN\fRth record (default 10).
  895. .TP
  896. \fB\-\-checkpoint\-action\fR=\fIACTION\fR
  897. Run \fIACTION\fR on each checkpoint.
  898. .TP
  899. \fB\-\-full\-time\fR
  900. Print file time to its full resolution.
  901. .TP
  902. \fB\-\-index\-file\fR=\fIFILE\fR
  903. Send verbose output to \fIFILE\fR.
  904. .TP
  905. \fB\-l\fR, \fB\-\-check\-links\fR
  906. Print a message if not all links are dumped.
  907. .TP
  908. \fB\-\-no\-quote\-chars\fR=\fISTRING\fR
  909. Disable quoting for characters from \fISTRING\fR.
  910. .TP
  911. \fB\-\-quote\-chars\fR=\fISTRING\fR
  912. Additionally quote characters from \fISTRING\fR.
  913. .TP
  914. \fB\-\-quoting\-style\fR=\fISTYLE\fR
  915. Set quoting style for file and member names. Valid values for
  916. \fISTYLE\fR are
  917. .BR literal ,
  918. .BR shell ,
  919. .BR shell-always ,
  920. .BR c ,
  921. .BR c-maybe ,
  922. .BR escape ,
  923. .BR locale ,
  924. .BR clocale .
  925. .TP
  926. \fB\-R\fR, \fB\-\-block\-number\fR
  927. Show block number within archive with each message.
  928. .TP
  929. \fB\-\-show\-omitted\-dirs\fR
  930. When listing or extracting, list each directory that does not match
  931. search criteria.
  932. .TP
  933. \fB\-\-show\-transformed\-names\fR, \fB\-\-show\-stored\-names\fR
  934. Show file or archive names after transformation by \fB\-\-strip\fR and
  935. \fB\-\-transform\fR options.
  936. .TP
  937. \fB\-\-totals\fR[=\fISIGNAL\fR]
  938. Print total bytes after processing the archive. If \fISIGNAL\fR is
  939. given, print total bytes when this signal is delivered. Allowed
  940. signals are:
  941. .BR SIGHUP ,
  942. .BR SIGQUIT ,
  943. .BR SIGINT ,
  944. .BR SIGUSR1 ", and"
  945. .BR SIGUSR2 .
  946. The \fBSIG\fR prefix can be omitted.
  947. .TP
  948. \fB\-\-utc\fR
  949. Print file modification times in UTC.
  950. .TP
  951. \fB\-v\fR, \fB\-\-verbose\fR
  952. Verbosely list files processed.
  953. .TP
  954. \fB\-\-warning\fR=\fIKEYWORD\fR
  955. Enable or disable warning messages identified by \fIKEYWORD\fR. The
  956. messages are suppressed if \fIKEYWORD\fR is prefixed with \fBno\-\fR
  957. and enabled otherwise.
  958. Multiple \fB\-\-warning\fR messages accumulate.
  959. Keywords controlling general \fBtar\fR operation:
  960. .RS
  961. .TP
  962. .B all
  963. Enable all warning messages. This is the default.
  964. .TP
  965. .B none
  966. Disable all warning messages.
  967. .TP
  968. .B filename-with-nuls
  969. "%s: file name read contains nul character"
  970. .TP
  971. .B alone-zero-block
  972. "A lone zero block at %s"
  973. .HP
  974. Keywords applicable for \fBtar --create\fR:
  975. .TP
  976. .B cachedir
  977. "%s: contains a cache directory tag %s; %s"
  978. .TP
  979. .B file-shrank
  980. "%s: File shrank by %s bytes; padding with zeros"
  981. .TP
  982. .B xdev
  983. "%s: file is on a different filesystem; not dumped"
  984. .TP
  985. .B file-ignored
  986. "%s: Unknown file type; file ignored"
  987. .br
  988. "%s: socket ignored"
  989. .br
  990. "%s: door ignored"
  991. .TP
  992. .B file-unchanged
  993. "%s: file is unchanged; not dumped"
  994. .TP
  995. .B ignore-archive
  996. "%s: file is the archive; not dumped"
  997. .TP
  998. .B file-removed
  999. "%s: File removed before we read it"
  1000. .TP
  1001. .B file-changed
  1002. "%s: file changed as we read it"
  1003. .HP
  1004. Keywords applicable for \fBtar --extract\fR:
  1005. .TP
  1006. .B existing\-file
  1007. "%s: skipping existing file"
  1008. .TP
  1009. .B timestamp
  1010. "%s: implausibly old time stamp %s"
  1011. .br
  1012. "%s: time stamp %s is %s s in the future"
  1013. .TP
  1014. .B contiguous-cast
  1015. "Extracting contiguous files as regular files"
  1016. .TP
  1017. .B symlink-cast
  1018. "Attempting extraction of symbolic links as hard links"
  1019. .TP
  1020. .B unknown-cast
  1021. "%s: Unknown file type '%c', extracted as normal file"
  1022. .TP
  1023. .B ignore-newer
  1024. "Current %s is newer or same age"
  1025. .TP
  1026. .B unknown-keyword
  1027. "Ignoring unknown extended header keyword '%s'"
  1028. .TP
  1029. .B decompress-program
  1030. Controls verbose description of failures occurring when trying to run
  1031. alternative decompressor programs. This warning is disabled by
  1032. default (unless \fB\-\-verbose\fR is used). A common example of what
  1033. you can get when using this warning is:
  1034. .EX
  1035. $ \fBtar --warning=decompress-program -x -f archive.Z
  1036. tar (child): cannot run compress: No such file or directory
  1037. tar (child): trying gzip
  1038. .EE
  1039. This means that \fBtar\fR first tried to decompress
  1040. \fBarchive.Z\fR using \fBcompress\fR, and, when that
  1041. failed, switched to \fBgzip\fR.
  1042. .TP
  1043. .B record-size
  1044. "Record size = %lu blocks"
  1045. .HP
  1046. Keywords controlling incremental extraction:
  1047. .TP
  1048. .B rename-directory
  1049. "%s: Directory has been renamed from %s"
  1050. .br
  1051. "%s: Directory has been renamed"
  1052. .TP
  1053. .B new-directory
  1054. "%s: Directory is new"
  1055. .TP
  1056. .B xdev
  1057. "%s: directory is on a different device: not purging"
  1058. .TP
  1059. .B bad-dumpdir
  1060. "Malformed dumpdir: 'X' never used"
  1061. .RE
  1062. .TP
  1063. \fB\-w\fR, \fB\-\-interactive\fR, \fB\-\-confirmation\fR
  1064. Ask for confirmation for every action.
  1065. .SS Compatibility options
  1066. .TP
  1067. \fB\-o\fR
  1068. When creating, same as \fB\-\-old\-archive\fR. When extracting, same
  1069. as \fB\-\-no\-same\-owner\fR.
  1070. .SS Size suffixes
  1071. .sp
  1072. .nf
  1073. .ta 8n 18n 42n
  1074. .ul
  1075. Suffix Units Byte Equivalent
  1076. b Blocks \fISIZE\fR x 512
  1077. B Kilobytes \fISIZE\fR x 1024
  1078. c Bytes \fISIZE\fR
  1079. G Gigabytes \fISIZE\fR x 1024^3
  1080. K Kilobytes \fISIZE\fR x 1024
  1081. k Kilobytes \fISIZE\fR x 1024
  1082. M Megabytes \fISIZE\fR x 1024^2
  1083. P Petabytes \fISIZE\fR x 1024^5
  1084. T Terabytes \fISIZE\fR x 1024^4
  1085. w Words \fISIZE\fR x 2
  1086. .fi
  1087. .PP
  1088. .SH "RETURN VALUE"
  1089. Tar exit code indicates whether it was able to successfully perform
  1090. the requested operation, and if not, what kind of error occurred.
  1091. .TP
  1092. .B 0
  1093. Successful termination.
  1094. .TP
  1095. .B 1
  1096. .I Some files differ.
  1097. If tar was invoked with the \fB\-\-compare\fR (\fB\-\-diff\fR, \fB\-d\fR)
  1098. command line option, this means that some files in the archive differ
  1099. from their disk counterparts. If tar was given one of the \fB\-\-create\fR,
  1100. \fB\-\-append\fR or \fB\-\-update\fR options, this exit code means
  1101. that some files were changed while being archived and so the resulting
  1102. archive does not contain the exact copy of the file set.
  1103. .TP
  1104. .B 2
  1105. .I Fatal error.
  1106. This means that some fatal, unrecoverable error occurred.
  1107. .PP
  1108. If a subprocess that had been invoked by
  1109. .B tar
  1110. exited with a nonzero exit code,
  1111. .B tar
  1112. itself exits with that code as well. This can happen, for example, if
  1113. a compression option (e.g. \fB\-z\fR) was used and the external
  1114. compressor program failed. Another example is
  1115. .B rmt
  1116. failure during backup to a remote device.
  1117. .SH "SEE ALSO"
  1118. .BR bzip2 (1),
  1119. .BR compress (1),
  1120. .BR gzip (1),
  1121. .BR lzma (1),
  1122. .BR lzop (1),
  1123. .BR rmt (8),
  1124. .BR symlink (7),
  1125. .BR tar (5),
  1126. .BR xz (1).
  1127. .PP
  1128. Complete \fBtar\fR manual: run
  1129. .B info tar
  1130. or use
  1131. .BR emacs (1)
  1132. info mode to read it.
  1133. .PP
  1134. Online copies of \fBGNU tar\fR documentation in various formats can be
  1135. found at:
  1136. .PP
  1137. .in +4
  1138. .B http://www.gnu.org/software/tar/manual
  1139. .SH "BUG REPORTS"
  1140. Report bugs to <bug\[email protected]>.
  1141. .SH COPYRIGHT
  1142. Copyright \(co 2013 Free Software Foundation, Inc.
  1143. .br
  1144. .na
  1145. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
  1146. .br
  1147. .ad
  1148. This is free software: you are free to change and redistribute it.
  1149. There is NO WARRANTY, to the extent permitted by law.
  1150. .\" Local variables:
  1151. .\" eval: (add-hook 'write-file-hooks 'time-stamp)
  1152. .\" time-stamp-start: ".TH [A-Z_][A-Z0-9_.\\-]* [0-9] \""
  1153. .\" time-stamp-format: "%:B %:d, %:y"
  1154. .\" time-stamp-end: "\""
  1155. .\" time-stamp-line-limit: 20
  1156. .\" end: