tarsnap.1-mdoc.in 38 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300
  1. .\" Copyright 2007-2009 Colin Percival
  2. .\" All rights reserved.
  3. .\"
  4. .\" Portions of the file below are covered by the following license:
  5. .\"
  6. .\" Copyright (c) 2003-2007 Tim Kientzle
  7. .\" All rights reserved.
  8. .\"
  9. .\" Redistribution and use in source and binary forms, with or without
  10. .\" modification, are permitted provided that the following conditions
  11. .\" are met:
  12. .\" 1. Redistributions of source code must retain the above copyright
  13. .\" notice, this list of conditions and the following disclaimer.
  14. .\" 2. Redistributions in binary form must reproduce the above copyright
  15. .\" notice, this list of conditions and the following disclaimer in the
  16. .\" documentation and/or other materials provided with the distribution.
  17. .\"
  18. .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  19. .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  20. .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  21. .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
  22. .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  23. .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  24. .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  25. .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  26. .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  27. .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  28. .\" SUCH DAMAGE.
  29. .\"
  30. .\" $FreeBSD: src/usr.bin/tar/bsdtar.1,v 1.46 2008/12/06 07:37:55 kientzle Exp $
  31. .\"
  32. .Dd @DATE@
  33. .Dt TARSNAP 1
  34. .Os
  35. .Sh NAME
  36. .Nm tarsnap
  37. .Nd manipulate remote encrypted backups
  38. .Sh SYNOPSIS
  39. .Nm
  40. .Brq Fl c
  41. .Fl -keyfile Ar key-file
  42. .Fl -cachedir Ar cache-dir
  43. .Fl f Ar archive-name
  44. .Op Ar options
  45. .Op Ar files | Ar directories
  46. .Nm
  47. .Brq Fl d
  48. .Fl -keyfile Ar key-file
  49. .Fl -cachedir Ar cache-dir
  50. .Fl f Ar archive-name
  51. .Op Ar options
  52. .Nm
  53. .Brq Fl t | Fl x
  54. .Fl -keyfile Ar key-file
  55. .Fl f Ar archive-name
  56. .Op Ar options
  57. .Op Ar patterns
  58. .Nm
  59. .Brq Fl r
  60. .Fl -keyfile Ar key-file
  61. .Fl f Ar archive-name
  62. .Nm
  63. .Brq Fl -list-archives
  64. .Fl -keyfile Ar key-file
  65. .Nm
  66. .Brq Fl -print-stats
  67. .Fl -keyfile Ar key-file
  68. .Fl -cachedir Ar cache-dir
  69. .Op Fl f Ar archive-name
  70. .Nm
  71. .Brq Fl -recover
  72. .Fl -keyfile Ar key-file
  73. .Fl -cachedir Ar cache-dir
  74. .Nm
  75. .Brq Fl -fsck
  76. .Fl -keyfile Ar key-file
  77. .Fl -cachedir Ar cache-dir
  78. .Nm
  79. .Brq Fl -fsck-prune
  80. .Fl -keyfile Ar key-file
  81. .Fl -cachedir Ar cache-dir
  82. .Nm
  83. .Brq Fl -initialize-cachedir
  84. .Fl -keyfile Ar key-file
  85. .Fl -cachedir Ar cache-dir
  86. .Nm
  87. .Brq Fl -nuke
  88. .Fl -keyfile Ar key-file
  89. .Nm
  90. .Fl -verify-config
  91. .Nm
  92. .Fl -version
  93. .Sh DESCRIPTION
  94. .Nm
  95. creates, reads, deletes, and otherwise manages online backups.
  96. .Pp
  97. The first option to
  98. .Nm
  99. is a mode indicator from the following list:
  100. .Bl -tag -compact -width indent
  101. .It Fl c
  102. Create an archive containing the specified items and name.
  103. .It Fl d
  104. Delete the specified archive.
  105. .It Fl t
  106. List archive contents to stdout.
  107. .It Fl x
  108. Extract to disk from the archive.
  109. .It Fl r
  110. Read the specified archive, convert it to a tar stream, and write it
  111. to stdout.
  112. .It Fl -list-archives
  113. Print the names of archives stored.
  114. If the
  115. .Fl v
  116. flag is specified one or more times, the creation
  117. time of each archive is also printed;
  118. if the
  119. .Fl v
  120. flag is specified two or more times, the command
  121. line with which
  122. .Nm
  123. was invoked to create each archive is also printed.
  124. .Pp
  125. If the
  126. .Fl -null
  127. argument is also specified, each archive name will be separated by a single
  128. null character.
  129. If the
  130. .Fl v
  131. flag is also specified, then the creation time will be separated by two null
  132. characters.
  133. If the
  134. .Fl v
  135. flag is specified two times, then the arguments in the command line will be
  136. separated by three null characters.
  137. .It Fl -print-stats
  138. Print global statistics concerning the archives stored, and optionally
  139. information about individual archive(s).
  140. See "PRINTING ARCHIVE STATISTICS" below for information on the output format.
  141. .It Fl -recover
  142. Recover a partial archive from a checkpoint if such an archive exists.
  143. This is also done automatically the next time an archive is created
  144. or deleted.
  145. .It Fl -fsck
  146. Perform some integrity checks on the archives stored, and reconstruct the
  147. cache directory
  148. .Ar cache-dir .
  149. In the unlikely event that there are corrupted archives,
  150. .Nm
  151. will exit and request that it be run with the
  152. .Fl -fsck-prune
  153. option.
  154. .It Fl -fsck-prune
  155. Run as
  156. .Fl -fsck ,
  157. but if corrupt archives are detected, prune the broken data.
  158. .It Fl -initialize-cachedir
  159. Create and initialize the cachedir.
  160. This option is intended for the GUI and is not needed for command-line usage.
  161. .It Fl -nuke
  162. Delete all of the archives stored.
  163. To protect against accidental data loss,
  164. .Nm
  165. will ask you to type the text "No Tomorrow" when using the
  166. .Fl -nuke
  167. command.
  168. .It Fl -verify-config
  169. Check the configuration file(s) for syntactic errors.
  170. .It Fl -version
  171. Print version number of
  172. .Nm ,
  173. and exit.
  174. .El
  175. .Pp
  176. In
  177. .Fl c
  178. mode, each specified file or directory is added to the
  179. archive in the order specified on the command line.
  180. By default, the contents of each directory are also archived.
  181. .Pp
  182. In
  183. .Fl t
  184. or
  185. .Fl x
  186. mode, the entire command line
  187. is read and parsed before the archive is opened.
  188. The pathnames or patterns on the command line indicate
  189. which items in the archive should be processed.
  190. Patterns are shell-style globbing patterns as
  191. documented in
  192. .Xr tcsh 1 .
  193. Note that these follow the POSIX rules for pattern matching, e.g.,
  194. .Sq []
  195. are special characters which can be escaped with a backslash.
  196. .Pp
  197. Two concurrent create or delete operations may not be performed with the same
  198. key.
  199. Extracting or listing archives may be performed in parallel with any other
  200. operation.
  201. .Sh OPTIONS
  202. .Bl -tag -width indent
  203. .It Cm @ Ns Pa archive-file
  204. (c mode only)
  205. The specified archive file is read and the entries
  206. in it will be appended to the current archive.
  207. If
  208. .Pa archive-file
  209. is
  210. .Dq -
  211. then the archive will be read from the standard input.
  212. As an example,
  213. .Dl Nm Fl c Fl -keyfile Ar key-file Fl -cachedir Ar cache-dir Fl f Ar mybackup Cm @ Ns Pa backup.tar
  214. reads the archive file
  215. .Pa backup.tar
  216. from disk and stores it using
  217. .Nm .
  218. .It Cm @@ Ns Ar archive-name
  219. (c mode only)
  220. The specified
  221. .Nm
  222. archive is read and the entries in it will be
  223. appended to the current archive.
  224. .It Fl -aggressive-networking
  225. (c mode only)
  226. Use multiple TCP connections to send data to the
  227. .Nm
  228. server.
  229. If the upload rate is congestion-limited rather than
  230. being limited by individual bottleneck(s), this may
  231. allow tarsnap to use a significantly larger fraction
  232. of the available bandwidth, at the expense of slowing
  233. down any other network traffic.
  234. .It Fl -archive-names Ar filename
  235. Read a list of archive names from
  236. .Ar filename .
  237. .It Fl C Ar directory
  238. (c and x modes only)
  239. In c mode, this changes the directory before adding
  240. the following files.
  241. In x mode, change directories after opening the archive
  242. but before extracting entries from the archive.
  243. .It Fl -cachedir Ar cache-dir
  244. (c, d, print-stats, and fsck modes only)
  245. Cache information about the archives stored by
  246. .Nm
  247. in the directory
  248. .Ar cache-dir .
  249. The contents of this directory will not be backed up by
  250. .Nm ,
  251. so it should not be used for any other purpose.
  252. If the directory
  253. .Ar cache-dir
  254. is lost, it can be reconstructed by running
  255. .Nm Fl -fsck .
  256. .It Fl -check-links
  257. (c mode only)
  258. Issue a warning message unless all links to each file are archived.
  259. .It Fl -checkpoint-bytes Ar bytespercheckpoint
  260. (c mode only)
  261. Create a checkpoint after every
  262. .Ar bytespercheckpoint
  263. bytes of uploaded data.
  264. The value
  265. .Ar bytespercheckpoint
  266. must be at least 1000000, and a higher value is recommended since
  267. creating a checkpoint in an archive can take a few seconds and several
  268. hundred kB of bandwidth.
  269. .It Fl -chroot
  270. (x mode only)
  271. .Fn chroot
  272. to the current directory after processing any
  273. .Fl C
  274. options and before extracting any files.
  275. .It Fl -configfile Ar filename
  276. Add
  277. .Ar filename
  278. to the list of configuration files to be read; options set via these take
  279. priority over the default configuration files.
  280. This option can be specified multiple times, in which case all the files
  281. will be read; where settings conflict, the earlier configuration file will
  282. take priority.
  283. .It Fl -creationtime Ar X
  284. (c mode only)
  285. Manually specify a creation time (a unix timestamp) for the archive.
  286. This is unlikely to be useful when tarsnap is being invoked directly from the
  287. command line.
  288. .It Fl -csv-file Ar filename
  289. (use with
  290. .Fl -print-stats )
  291. Write statistics in CSV format to a file.
  292. .It Fl -disk-pause Ar X
  293. (c mode only)
  294. Pause for
  295. .Ar X
  296. ms between storing archive entries and after every 64 kB of file data.
  297. This will slow down
  298. .Nm
  299. and thereby reduce its impact on other applications.
  300. For archiving files which are stored on an ATA disk and are not in the
  301. operating system disk cache, a value of
  302. .Fl -disk-pause Ar 10
  303. will approximately double the time taken.
  304. .It Fl -dry-run
  305. (c mode only)
  306. Don't really create an archive; just simulate doing so.
  307. The list of paths added to an archive (if the
  308. .Fl v
  309. option is used), progress messages (if the
  310. .Fl -progress-bytes
  311. option is used), and final statistics printed (if the
  312. .Fl -print-stats
  313. option is used) will be almost identical (typically
  314. within a few kB or a fraction of a percent) to if
  315. .Nm
  316. is run without the
  317. .Fl -dry-run
  318. option.
  319. .Pp
  320. Note that the
  321. .Fl -maxbw
  322. option does not work in combination with
  323. .Fl -dry-run ,
  324. since no bandwidth is actually used, and that since
  325. .Nm
  326. does not contact the
  327. .Nm
  328. server when performing a dry run, it will not detect an
  329. attempt to create an archive with the same name as one
  330. which already exists.
  331. If an existing archive is being copied via
  332. .Cm @@ Ns Ar archive-name ,
  333. then some network bandwidth will be used while
  334. .Nm
  335. reads metadata about
  336. .Ar archive-name
  337. from the tarsnap server.
  338. .Pp
  339. Furthermore,
  340. .Fl -dry-run
  341. will not check whether the cache directory is out of sync.
  342. .It Fl -dry-run-metadata
  343. (c mode only)
  344. Don't really create an archive; just simulate doing so.
  345. This is similar to
  346. .Fl -dry-run ,
  347. except that it doesn't read any files; it only processes filesystem metadata.
  348. .Pp
  349. This is significantly faster than a regular
  350. .Fl -dry-run ,
  351. but it is still suitable for checking which filesystem entries will be
  352. archived (with
  353. .Fl v ) ,
  354. or getting the total uncompressed archive size (via
  355. .Fl -totals
  356. or
  357. .Fl -progress-bytes ) .
  358. .Pp
  359. This option cannot be used with
  360. .Fl -print-stats .
  361. .It Fl -dump-config
  362. Print out the command-line and all non-blank lines read from config files.
  363. .It Fl -exclude Ar pattern
  364. (c, x, and t modes only)
  365. Do not process files or directories that match the
  366. specified pattern.
  367. Note that exclusions take precedence over patterns or filenames
  368. specified on the command line.
  369. .It Fl f Ar archive-name
  370. (c, d, x, t, r, list-archives, and print-stats modes only)
  371. Operate on the archive
  372. .Ar archive-name .
  373. In mode c, if archive creation is interrupted by \&^Q,
  374. the SIGQUIT signal, or reaching the bandwidth limit
  375. specified via a
  376. .Fl -maxbw
  377. option, the archive will be stored with
  378. ".part" appended to its name.
  379. In mode print-stats, if
  380. .Ar archive-name
  381. is *, statistics will be printed for every archive.
  382. In the print-stats and d modes,
  383. .Fl f Ar archive-name
  384. can be specified multiple times, in which case the operation
  385. (printing statistics, or deletion) will be performed for each
  386. of the specified archives.
  387. .Pp
  388. Note that each archive created must have a different name; consequently
  389. many users find it useful to include timestamps in archive names when
  390. repeatedly creating archives from the same files/directories (e.g.,
  391. daily backups).
  392. .Pp
  393. As a special case, if used with
  394. .Fl -list-archives -hashes
  395. then
  396. .Fl f
  397. indicates a
  398. .Ar tapehash
  399. instead of an
  400. .Ar archive-name ,
  401. and will print metadata about the specified archive(s).
  402. This combination of options is intended for the GUI and is not needed for
  403. command-line usage.
  404. .Po Fl f
  405. cannot be used with
  406. .Fl -list-archives
  407. if it does not also include
  408. .Fl -hashes .
  409. .Pc
  410. .It Fl -force-resources
  411. Force the decryption of a passphrase-encrypted key file to proceed
  412. even if it is anticipated to require an excessive amount of memory
  413. or CPU time.
  414. .It Fl H
  415. (c mode only)
  416. Symbolic links named on the command line will be followed; the
  417. target of the link will be archived, not the link itself.
  418. .It Fl h
  419. (c mode only)
  420. Synonym for
  421. .Fl L .
  422. .It Fl -hashes
  423. (list-archives mode only)
  424. Print hashes of archive names.
  425. If the
  426. .Fl v
  427. flag is specified one or more times, print the archive name as well.
  428. .Pp
  429. This option is intended for the GUI and is not needed for command-line usage.
  430. .It Fl -humanize-numbers
  431. Use SI prefixes to make numbers printed by
  432. .Fl -print-stats
  433. and SIGINFO more readable.
  434. .It Fl I
  435. Synonym for
  436. .Fl T .
  437. .It Fl -include Ar pattern
  438. (c, x, and t modes only)
  439. Process only files or directories that match the specified pattern.
  440. Note that exclusions specified with
  441. .Fl -exclude
  442. take precedence over inclusions.
  443. If no inclusions are explicitly specified, all entries are processed by
  444. default.
  445. The
  446. .Fl -include
  447. option is especially useful when filtering archives.
  448. For example, the command
  449. .Dl Nm Fl c Fl f Ar foo-backup Fl -include='*foo*' Cm @@ Ns Ar all-backup
  450. creates a new archive
  451. .Ar foo-backup
  452. containing only the entries from
  453. .Ar all-backup
  454. containing the string
  455. .Sq foo .
  456. .It Fl -insane-filesystems
  457. (c mode only)
  458. Allow descent into synthetic filesystems such as procfs.
  459. Normally archiving of such filesystems is a silly thing to do, hence the
  460. name of the option.
  461. .It Fl -iso-dates
  462. (t mode only)
  463. Print file and directory dates as yyyy-mm-dd hh:mm:ss.
  464. .Pp
  465. The default is to use the same format as 'ls -l': If the files were modified
  466. within the past six months, print the month, day, hour, and minutes; otherwise,
  467. print the month, day, and year.
  468. .It Fl k
  469. (x mode only)
  470. Do not overwrite existing files.
  471. In particular, if a file appears more than once in an archive,
  472. later copies will not overwrite earlier copies.
  473. .It Fl -keep-going
  474. (d and print-stats modes only)
  475. Continue deleting or printing statistics after finding that one
  476. of the archives specified does not exist.
  477. .It Fl -keep-newer-files
  478. (x mode only)
  479. Do not overwrite existing files that are newer than the
  480. versions appearing in the archive being extracted.
  481. .It Fl -keyfile Pa key-file
  482. (all modes)
  483. Obtain encryption, authentication, and access keys from
  484. .Ar key-file .
  485. This file should have been generated by
  486. .Xr tarsnap-keygen 1 .
  487. .It Fl L
  488. (c mode only)
  489. All symbolic links will be followed.
  490. Normally, symbolic links are archived as such.
  491. With this option, the target of the link will be archived instead.
  492. .It Fl l
  493. This is a synonym for the
  494. .Fl -check-links
  495. option.
  496. .It Fl -lowmem
  497. (c mode only)
  498. Reduce memory usage by not caching small files.
  499. This may be useful when backing up files of average size less
  500. than 1 MB if the available RAM in kilobytes is less than the
  501. number of files being backed up.
  502. .It Fl m
  503. (x mode only)
  504. Do not extract modification time.
  505. By default, the modification time is set to the time stored in the archive.
  506. .It Fl -maxbw Ar numbytes
  507. (c mode only)
  508. Interrupt archival if more than
  509. .Ar numbytes
  510. bytes of upstream bandwidth is used (see INTERRUPTING ARCHIVAL
  511. below for details).
  512. .It Fl -maxbw-rate Ar bytespersecond
  513. Limit download and upload bandwidth used to
  514. .Ar bytespersecond
  515. bytes per second.
  516. .It Fl -maxbw-rate-down Ar bytespersecond
  517. Limit download bandwidth used to
  518. .Ar bytespersecond
  519. bytes per second.
  520. .It Fl -maxbw-rate-up Ar bytespersecond
  521. Limit upload bandwidth used to
  522. .Ar bytespersecond
  523. bytes per second.
  524. .It Fl n
  525. (c mode only)
  526. Do not recursively archive the contents of directories.
  527. .It Fl -newer Ar date
  528. (c, x, t modes only)
  529. Only include files and directories newer than the specified date.
  530. This compares ctime entries.
  531. .It Fl -newer-mtime Ar date
  532. (c mode only)
  533. Like
  534. .Fl -newer ,
  535. except it compares mtime entries instead of ctime entries.
  536. .It Fl -newer-than Pa filename
  537. (c mode only)
  538. Only include files and directories newer than the specified file.
  539. This compares ctime entries.
  540. .It Fl -newer-mtime-than Pa filename
  541. (c mode only)
  542. Like
  543. .Fl -newer-than ,
  544. except it compares mtime entries instead of ctime entries.
  545. .It Fl -no-aggressive-networking
  546. Ignore any
  547. .Cm aggressive-networking
  548. option specified in a configuration file.
  549. .It Fl -no-config-exclude
  550. Ignore any
  551. .Cm exclude
  552. option specified in a configuration file.
  553. Normally
  554. .Cm exclude
  555. options specified via configuration files and the command line
  556. all take effect.
  557. .It Fl -no-config-include
  558. Ignore any
  559. .Cm include
  560. option specified in a configuration file.
  561. Normally
  562. .Cm include
  563. options specified via configuration files and the command line
  564. all take effect.
  565. .It Fl -no-default-config
  566. Do not read the default configuration files
  567. .Pa @sysconfdir@/tarsnap.conf ,
  568. .Pa $XDG_CONFIG_HOME/tarsnap/tarsnap.conf ,
  569. and
  570. .Pa ~/.tarsnaprc .
  571. .It Fl -no-disk-pause
  572. Ignore any
  573. .Cm disk-pause
  574. option specified in a configuration file.
  575. .It Fl -no-force-resources
  576. Ignore any
  577. .Cm force-resources
  578. option specified in a configuration file.
  579. .It Fl -no-humanize-numbers
  580. Ignore any
  581. .Cm humanize-numbers
  582. option specified in a configuration file.
  583. .It Fl -no-insane-filesystems
  584. Ignore any
  585. .Cm insane-filesystems
  586. option specified in a configuration file.
  587. .It Fl -no-iso-dates
  588. Ignore any
  589. .Cm iso-dates
  590. option specified in a configuration file.
  591. .It Fl -no-maxbw
  592. Ignore any
  593. .Cm maxbw
  594. option specified in a configuration file.
  595. .It Fl -no-maxbw-rate-down
  596. Ignore any
  597. .Cm maxbw-rate-down
  598. option specified in a configuration file.
  599. If a
  600. .Cm maxbw-rate
  601. option is specified in a configuration file, it will
  602. not affect the download bandwidth used, but may affect
  603. the upload bandwidth used (unless
  604. .Fl -no-maxbw-rate-up
  605. is also specified).
  606. .It Fl -no-maxbw-rate-up
  607. Ignore any
  608. .Cm maxbw-rate-up
  609. option specified in a configuration file.
  610. If a
  611. .Cm maxbw-rate
  612. option is specified in a configuration file, it will
  613. not affect the upload bandwidth used, but may affect
  614. the download bandwidth used (unless
  615. .Fl -no-maxbw-rate-down
  616. is also specified).
  617. .It Fl -no-nodump
  618. Ignore any
  619. .Cm nodump
  620. option specified in a configuration file.
  621. .It Fl -no-print-stats
  622. Ignore any
  623. .Cm print-stats
  624. option specified in a configuration file.
  625. .It Fl -no-progress-bytes
  626. Ignore any
  627. .Cm progress-bytes
  628. option specified in a configuration file.
  629. .It Fl -no-quiet
  630. Ignore any
  631. .Cm quiet
  632. option specified in a configuration file.
  633. .It Fl -no-retry-forever
  634. Ignore any
  635. .Cm retry-forever
  636. option specified in a configuration file.
  637. .It Fl -no-snaptime
  638. Ignore any
  639. .Cm snaptime
  640. option specified in a configuration file.
  641. .It Fl -no-store-atime
  642. Ignore any
  643. .Cm store-atime
  644. option specified in a configuration file.
  645. .It Fl -no-totals
  646. Ignore any
  647. .Cm totals
  648. option specified in a configuration file.
  649. .It Fl -nodump
  650. (c mode only)
  651. Honor the nodump file flag by skipping this file or directory.
  652. .It Fl -noisy-warnings
  653. Be verbose when warning about network glitches.
  654. This is probably only useful for debugging purposes.
  655. .It Fl -normalmem
  656. Ignore any
  657. .Cm lowmem
  658. or
  659. .Cm verylowmem
  660. option specified in a configuration file.
  661. .It Fl -null
  662. (use with
  663. .Fl I ,
  664. .Fl T ,
  665. .Fl X ,
  666. or list-archives modes only)
  667. Filenames or patterns are separated by null characters,
  668. not by newlines.
  669. This is often used to read filenames output by the
  670. .Fl print0
  671. option to
  672. .Xr find 1 .
  673. .It Fl -numeric-owner
  674. (x mode only)
  675. Ignore symbolic user and group names when restoring archives to disk,
  676. only numeric uid and gid values will be obeyed.
  677. .It Fl O
  678. (x and t modes only)
  679. In extract (-x) mode, files will be written to standard out rather than
  680. being extracted to disk.
  681. In list (-t) mode, the file listing will be written to stderr rather than
  682. the usual stdout.
  683. .It Fl o
  684. (x mode only)
  685. Use the user and group of the user running the program rather
  686. than those specified in the archive.
  687. Note that this has no significance unless
  688. .Fl p
  689. is specified, and the program is being run by the root user.
  690. In this case, the file modes and flags from
  691. the archive will be restored, but ACLs or owner information in
  692. the archive will be discarded.
  693. .It Fl -one-file-system
  694. (c mode only)
  695. Do not cross mount points.
  696. .It Fl P
  697. (c, x, and t modes only)
  698. Preserve pathnames.
  699. By default, absolute pathnames (those that begin with a /
  700. character) have the leading slash removed both when creating archives
  701. and extracting from them.
  702. Also,
  703. .Nm
  704. will refuse to extract archive entries whose pathnames contain
  705. .Pa ..
  706. or whose target directory would be altered by a symlink.
  707. This option suppresses these behaviors.
  708. .It Fl p
  709. (x mode only)
  710. Preserve file permissions.
  711. Attempt to restore the full permissions, including owner, file modes, file
  712. flags and ACLs, if available, for each item extracted from the archive.
  713. By default, newly-created files are owned by the user running
  714. .Nm ,
  715. the file mode is restored for newly-created regular files, and
  716. all other types of entries receive default permissions.
  717. If
  718. .Nm
  719. is being run by root, the default is to restore the owner unless the
  720. .Fl o
  721. option is also specified.
  722. .It Fl -passphrase Ar method:arg
  723. Read the passphrase using the specified method.
  724. .Bl -tag -width aa
  725. .It Ar dev:tty-stdin
  726. Attempt to read the passphrase from /dev/tty; if that fails, read it from stdin.
  727. This is the default behaviour.
  728. .It Ar dev:stdin-once
  729. Attempt to read the passphrase from stdin, and do so only once even when
  730. encrypting.
  731. This cannot be used if
  732. .Ar infile
  733. is also stdin (aka '-').
  734. .It Ar dev:tty-once
  735. Attempt to read the passphrase from /dev/tty, and do so only once
  736. even when encrypting.
  737. .It Ar env:VAR
  738. Read the passphrase from the environment variable specified by
  739. .Ar VAR .
  740. .Pp
  741. .Bf Em
  742. Storing a passphrase in an environment variable may be a security risk.
  743. .Ef
  744. Only use this option if you are certain that you know what you are doing.
  745. .It Ar file:FILENAME
  746. Read the passphrase from the file specified by
  747. .Ar FILENAME .
  748. .Pp
  749. .Bf Em
  750. Storing a passphrase in a file may be a security risk.
  751. .Ef
  752. Only use this option if you are certain that you know what you are doing.
  753. .El
  754. .It Fl -print-stats
  755. (c and d modes only)
  756. Print statistics for the archive being created (c mode) or delete (d mode).
  757. See "PRINTING ARCHIVE STATISTICS" below for information on the output format.
  758. .It Fl -progress-bytes Ar X
  759. Display a progress message (as if generated from SIGUSR1 or SIGINFO) after
  760. processing each
  761. .Ar X
  762. bytes.
  763. Occurs at most once per file.
  764. .It Fl q ( Fl -fast-read )
  765. (x and t modes only)
  766. Extract or list only the first archive entry that matches each pattern
  767. or filename operand.
  768. Exit as soon as each specified pattern or filename has been matched.
  769. By default, the archive is always read to the very end, since
  770. there can be multiple entries with the same name and, by convention,
  771. later entries overwrite earlier entries.
  772. This option is provided as a performance optimization.
  773. .It Fl -quiet
  774. Avoid printing some warnings.
  775. Currently the warnings which are silenced by this option are
  776. "Removing leading '/' ...",
  777. "Not adding cache directory to archive",
  778. "... file may have grown while being archived",
  779. and
  780. "Skipping entry on filesystem of type ...",
  781. but it is likely that other
  782. warnings will be silenced by this option in future versions of
  783. .Nm .
  784. .It Fl -resume-extract
  785. (x mode only)
  786. Don't extract files whose filesize and mtime matches existing files on the
  787. disk.
  788. Primarily used to resume an archive extraction which was interrupted.
  789. The mtime comparison ignores sub-second timestamp precision, as this is not
  790. supported on all filesystems.
  791. This differs from
  792. .Fl k
  793. in that
  794. .Fl -resume-extract
  795. will overwrite a file if the size or modification time do not match, as can
  796. happen if tarsnap is killed partway through extracting a file.
  797. .It Fl -retry-forever
  798. This option causes tarsnap to continue trying to reconnect to the
  799. tarsnap server forever, instead of giving up after 5-10 minutes.
  800. This may be useful for people with excessively flaky networks, or
  801. on mobile devices which regularly lose their internet connections
  802. for extended periods of time.
  803. This is not enabled by default since continued failures generally indicate a
  804. problem which should be investigated by the user.
  805. .It Fl S
  806. (x mode only)
  807. Extract files as sparse files.
  808. For every block on disk, check first if it contains any non-NULL bytes and seek
  809. over it otherwise.
  810. This works similar to the conv=sparse option of dd.
  811. .It Fl s Ar pattern
  812. Modify file or archive member names according to
  813. .Pa pattern .
  814. The pattern has the format /old/new/[gps].
  815. old is a basic regular expression.
  816. If it doesn't apply, the pattern is skipped.
  817. new is the replacement string of the matched part.
  818. ~ is substituted with the match, \e1 to \e9 with the contents of
  819. the corresponding captured group.
  820. The optional trailing g specifies that matching should continue
  821. after the matched part and stop on the first unmatched pattern.
  822. The optional trailing s specifies that the pattern applies to the value
  823. of symbolic links.
  824. The optional trailing p specifies that after a successful substitution
  825. the original path name and the new path name should be printed to
  826. standard error.
  827. .It Fl -snaptime Pa filename
  828. (c mode only)
  829. This option MUST be specified when creating a backup from a filesystem
  830. snapshot, and
  831. .Pa filename
  832. must have a modification time prior to when the filesystem snapshot was
  833. created.
  834. (This is necessary to prevent races between file modification and snapshot
  835. creation which could result in
  836. .Nm
  837. failing to recognize that a file has been modified.)
  838. .It Fl -store-atime
  839. (c mode only)
  840. Enable the storing of file access times.
  841. The default behaviour of
  842. .Nm
  843. is to not store file access times, since this can cause a significant amount
  844. of bandwidth and storage to be wasted when the same set of files are archived
  845. several times (e.g., if daily backup archives are created) due to
  846. .Nm
  847. itself accessing files and thereby causing their access times to be changed.
  848. .It Fl -strip-components Ar count
  849. (x mode only)
  850. Remove the specified number of leading path elements.
  851. Pathnames with fewer elements will be silently skipped.
  852. Note that the pathname is edited after checking inclusion/exclusion patterns
  853. but before security checks.
  854. .It Fl T Ar filename
  855. (c, x, and t modes only)
  856. In x or t mode,
  857. .Nm
  858. will read the list of names to be extracted from
  859. .Pa filename .
  860. In c mode,
  861. .Nm
  862. will read names to be archived from
  863. .Pa filename .
  864. The special name
  865. .Dq -C
  866. on a line by itself will cause the current directory to be changed to
  867. the directory specified on the following line.
  868. Names are terminated by newlines unless
  869. .Fl -null
  870. is specified.
  871. Note that
  872. .Fl -null
  873. also disables the special handling of lines containing
  874. .Dq -C .
  875. If
  876. .Pa filename
  877. is
  878. .Dq -
  879. then the list of names will be read from the standard input.
  880. Note: If you are generating lists of files using
  881. .Xr find 1 ,
  882. you probably want to use
  883. .Fl n
  884. as well.
  885. .It Fl -totals
  886. (c mode only)
  887. Print the size of the archive after creating it.
  888. This option is provided mainly for compatibility with GNU tar; in most
  889. situations the
  890. .Fl -print-stats
  891. option will be far more useful.
  892. .It Fl U
  893. (x mode only)
  894. Unlink files before creating them.
  895. Without this option,
  896. .Nm
  897. overwrites existing files, which preserves existing hardlinks.
  898. With this option, existing hardlinks will be broken, as will any
  899. symlink that would affect the location of an extracted file.
  900. .It Fl v
  901. (c, d, t, x, and list-archives modes only)
  902. Produce verbose output.
  903. In create and extract modes,
  904. .Nm
  905. will list each file name as it is read from or written to
  906. the archive.
  907. In delete mode,
  908. .Nm
  909. will list the name of each archive as it is deleted.
  910. In list mode,
  911. .Nm
  912. will produce output similar to that of
  913. .Xr ls 1 .
  914. Additional
  915. .Fl v
  916. options will provide additional detail.
  917. .It Fl -verify-config
  918. Check the configuration file(s) for syntactic errors.
  919. .It Fl -version
  920. Print version number of
  921. .Nm ,
  922. and exit.
  923. .It Fl -verylowmem
  924. (c mode only)
  925. Reduce memory usage, by approximately a factor of 2 beyond
  926. the memory usage when
  927. .Fl -lowmem
  928. is specified, by not caching anything.
  929. .It Fl w
  930. (c and x modes only)
  931. Ask for confirmation for every action.
  932. .It Fl X Ar filename
  933. (c, x, and t modes only)
  934. Read a list of exclusion patterns from the specified file.
  935. See
  936. .Fl -exclude
  937. for more information about the handling of exclusions.
  938. .El
  939. .Sh SIGNALS
  940. .Nm
  941. handles the following signals:
  942. .Bl -tag -width "SIGUSR2"
  943. .It SIGUSR1 & SIGINFO
  944. On receipt of the SIGUSR1 signal or (on platforms where it exists) the
  945. SIGINFO signal,
  946. .Nm
  947. prints the current file or directory being processed, and (for files)
  948. its progress within the file.
  949. It also prints the number of files and the number of uncompressed bytes
  950. processed.
  951. Note that due to network buffering the file position will not align precisely
  952. with how much data has been sent to or received from the
  953. .Nm
  954. server.
  955. .It SIGSTOP & SIGTSTP
  956. On receipt of a SIGSTOP or SIGTSTP signal, the kernel will suspend the
  957. .Nm
  958. process.
  959. Upon receiving a SIGCONT signal,
  960. .Nm
  961. will reconnect to the server (if necessary) and continue the specified task.
  962. .It SIGUSR2
  963. On receipt of the SIGUSR2 signal, if
  964. .Nm
  965. is creating an archive (mode c), it will create a checkpoint at the
  966. current position.
  967. .It SIGQUIT
  968. On receipt of the SIGQUIT signal, if
  969. .Nm
  970. is creating an archive (mode c) it will truncate the archive at the
  971. current position and exit (see "INTERRUPTING ARCHIVAL" below).
  972. .El
  973. .Sh PRINTING ARCHIVE STATISTICS
  974. There are four commands which print statistics about archives:
  975. .Bl -bullet -width indent
  976. .It
  977. Global statistics:
  978. .Dl Nm Fl -print-stats
  979. .It
  980. Global statistics and info about specific archive(s):
  981. .Dl Nm Fl -print-stats Fl f Ar archive-name1 Op Fl f Ar ...
  982. .It
  983. Global statistics and info about all archives:
  984. .Dl Nm Fl -print-stats Fl f Ar '*'
  985. .It
  986. Global statistics and info about the archive(s) that were just created or
  987. deleted:
  988. .Dl Nm Fl c Fl -print-stats Fl f Ar archive-name Ar DIR
  989. .Dl Nm Fl d Fl -print-stats Fl f Ar archive-name1 Op Fl f Ar ...
  990. .El
  991. .Pp
  992. .Nm
  993. will print a table in the following format:
  994. .Bd -literal
  995. Total size Compressed size
  996. All archives 104491640436 51510524844
  997. (unique data) 14830618089 7733620463
  998. This archive 808723344 289077325
  999. New data 17858641 5658308
  1000. .Ed
  1001. .Pp
  1002. In this example, the combined size of all archives stored by
  1003. .Nm
  1004. using the same keys is 104 GB, and the combined size post-compression
  1005. would be 51 GB; but after removing duplicate blocks, there is only 14.8 GB
  1006. which is compressed down to 7.7 GB.
  1007. (It is this 7.7 GB which is stored via the Tarsnap service and must
  1008. thus be paid for.)
  1009. The newly created archive is 808 MB in size (compressible to 289 MB), but
  1010. only 17.8 MB of the data is new, and after compression only 5.6 MB is
  1011. uploaded to the Tarsnap server.
  1012. .Pp
  1013. When
  1014. .Nm
  1015. .Fl -print-stats
  1016. is executed as a command, the table is printed to the standard output;
  1017. when the
  1018. .Fl -print-stats
  1019. option is used while creating or deleting archives, the table is printed
  1020. to the standard error device.
  1021. .Pp
  1022. Global statistics are calculated based on the current cache directory, without
  1023. using the keyfile or querying the Tarsnap servers.
  1024. .Sh INTERRUPTING ARCHIVAL
  1025. Upon receipt of the
  1026. .Dv SIGQUIT
  1027. signal or \&^Q,
  1028. or if the bandwidth limit specified via a
  1029. .Fl -maxbw
  1030. option is reached,
  1031. .Nm
  1032. will interrupt the creation of an archive and truncate it
  1033. at the current position.
  1034. When an archive is truncated, it will be named according to
  1035. the user-specified name plus ".part" to denote the fact that
  1036. it is incomplete.
  1037. Such a truncated archive may be useful in its own right, but
  1038. also offers the benefit that future attempts to archive the
  1039. same data will be faster and use less bandwidth.
  1040. .Sh FIREWALLS
  1041. .Nm
  1042. communicates with the
  1043. .Nm
  1044. server via a TCP connection to port 9279; in some environments
  1045. it may be necessary to add a firewall rule to allow outgoing
  1046. TCP connections to this port.
  1047. At the present time (July 2009) there is only one IP address in
  1048. use for the
  1049. .Nm
  1050. server, so network administrators may wish to hard-code that IP
  1051. address; however, it is likely that at some point in the future
  1052. that IP address will change and/or other IP addresses will be
  1053. added.
  1054. .Sh ENVIRONMENT
  1055. The following environment variables affect the execution of
  1056. .Nm :
  1057. .Bl -tag -width ".Ev BLOCKSIZE"
  1058. .It Ev LANG
  1059. The locale to use.
  1060. See
  1061. .Xr environ 7
  1062. for more information.
  1063. .It Ev TZ
  1064. The timezone to use when displaying dates.
  1065. See
  1066. .Xr environ 7
  1067. for more information.
  1068. .El
  1069. .Sh FILES
  1070. .Bl -tag -width indent
  1071. .It Pa @sysconfdir@/tarsnap.conf
  1072. The system global
  1073. .Nm
  1074. configuration file.
  1075. Parameters specified here only take effect if they are not
  1076. specified via the current user's local configuration file
  1077. or via the command line.
  1078. .It Pa $XDG_CONFIG_HOME/tarsnap/tarsnap.conf
  1079. A
  1080. .Nm
  1081. configuration file for the current user.
  1082. If the environment variable
  1083. .Ev XDG_CONFIG_HOME
  1084. is empty, the default value of
  1085. .Pa ~/.config/tarsnap/tarsnap.conf
  1086. will be used.
  1087. Parameters specified here take effect unless they are specified via
  1088. .Pa ~/.tarsnaprc
  1089. or the command line.
  1090. .It Pa ~/.tarsnaprc
  1091. Another location for the
  1092. .Nm
  1093. configuration file for the current user.
  1094. Parameters specified here take effect unless they are
  1095. specified via the command line.
  1096. .El
  1097. .Sh EXIT STATUS
  1098. .Ex -std
  1099. .Pp
  1100. An exit code of 2 indicates that an error has occurred and the server-side
  1101. state was modified.
  1102. .Sh EXAMPLES
  1103. Register with the server and generate keys:
  1104. .Dl Nm tarsnap-keygen Fl -keyfile Pa /usr/tarsnap.key Fl -user Ar me@example.com Fl -machine Ar myserver
  1105. .Pp
  1106. Perform a backup of
  1107. .Pa /usr/home
  1108. and
  1109. .Pa /other/stuff/to/backup :
  1110. .Dl Nm Fl -keyfile Pa /usr/tarsnap.key Fl -cachedir Pa /usr/tarsnap-cache Fl c Fl f Ar backup-2008-04-24 Pa /usr/home Pa /other/stuff/to/backup
  1111. .Pp
  1112. Perform another backup, a day later;
  1113. this is much faster since tarsnap will avoid
  1114. storing data which was previously stored:
  1115. .Dl Nm Fl -keyfile Pa /usr/tarsnap.key Fl -cachedir Pa /usr/tarsnap-cache Fl c Fl f Ar backup-2008-04-25 Pa /usr/home Pa /other/stuff/to/backup
  1116. .Pp
  1117. List the archives:
  1118. .Dl Nm Fl -keyfile Pa /usr/tarsnap.key Fl -list-archives
  1119. .Pp
  1120. Delete the first backup, leaving the second backup intact:
  1121. .Dl Nm Fl -keyfile Pa /usr/tarsnap.key Fl -cachedir Pa /usr/tarsnap-cache Fl d Fl f Ar backup-2008-04-24
  1122. .Pp
  1123. List the files in the remaining backup:
  1124. .Dl Nm Fl -keyfile Pa /usr/tarsnap.key Fl tv Fl f Ar backup-2008-04-25
  1125. .Pp
  1126. Restore two users' home directories from the backup:
  1127. .Dl Nm Fl -keyfile Pa /usr/tarsnap.key Fl x Fl f Ar backup-2008-04-25 Pa usr/home/auser Pa usr/home/anotheruser
  1128. .Pp
  1129. In
  1130. .Pa /etc/crontab
  1131. to create a backup of the entire system at 10:32 each day:
  1132. .Dl 32 10 * * * root Nm Fl -keyfile Pa /usr/tarsnap.key Fl -cachedir Pa /usr/tarsnap-cache Fl c Fl f Ar backup-`date +\e%Y\e%m\e%d` Pa /
  1133. .Pp
  1134. Note that the
  1135. .Fl -keyfile
  1136. and
  1137. .Fl -cachedir
  1138. options can be specified via the
  1139. .Xr tarsnap.conf 5
  1140. configuration file, in which case they may be omitted
  1141. from the command line.
  1142. .Sh SECURITY
  1143. Certain security issues are common to many archiving programs, including
  1144. .Nm .
  1145. In particular, carefully-crafted archives can request that
  1146. .Nm
  1147. extract files to locations outside of the target directory.
  1148. This can potentially be used to cause unwitting users to overwrite
  1149. files they did not intend to overwrite.
  1150. If the archive is being extracted by the superuser, any file
  1151. on the system can potentially be overwritten.
  1152. There are three ways this can happen.
  1153. Although
  1154. .Nm
  1155. has mechanisms to protect against each one,
  1156. savvy users should be aware of the implications:
  1157. .Bl -bullet -width indent
  1158. .It
  1159. Archive entries can have absolute pathnames.
  1160. By default,
  1161. .Nm
  1162. removes the leading
  1163. .Pa /
  1164. character from filenames before restoring them to guard against this problem.
  1165. .It
  1166. Archive entries can have pathnames that include
  1167. .Pa ..
  1168. components.
  1169. By default,
  1170. .Nm
  1171. will not extract files containing
  1172. .Pa ..
  1173. components in their pathname.
  1174. .It
  1175. Archive entries can exploit symbolic links to restore
  1176. files to other directories.
  1177. An archive can restore a symbolic link to another directory,
  1178. then use that link to restore a file into that directory.
  1179. To guard against this,
  1180. .Nm
  1181. checks each extracted path for symlinks.
  1182. If the final path element is a symlink, it will be removed
  1183. and replaced with the archive entry.
  1184. If
  1185. .Fl U
  1186. is specified, any intermediate symlink will also be unconditionally removed.
  1187. If neither
  1188. .Fl U
  1189. nor
  1190. .Fl P
  1191. is specified,
  1192. .Nm
  1193. will refuse to extract the entry.
  1194. .El
  1195. .Pp
  1196. Although
  1197. .Nm
  1198. cryptographically signs archives in such a manner that it is believed
  1199. to be unfeasible for an attacker to forge an archive without having
  1200. possession of
  1201. .Ar key-file ,
  1202. you may wish to examine the contents of archive(s) with
  1203. .Dl Nm Fl t Fl -keyfile Ar key-file Fl f Ar archive-name
  1204. before extraction.
  1205. Note that the
  1206. .Fl P
  1207. option to
  1208. .Nm
  1209. disables the security checks above and allows you to extract
  1210. an archive while preserving any absolute pathnames,
  1211. .Pa ..
  1212. components, or symlinks to other directories.
  1213. .Sh SEE ALSO
  1214. .Xr tarsnap-keygen 1 ,
  1215. .Xr tar 5 ,
  1216. .Xr tarsnap.conf 5
  1217. .Sh HISTORY
  1218. A
  1219. .Nm tar
  1220. command appeared in Seventh Edition Unix, which was
  1221. released in January, 1979.
  1222. There have been numerous other implementations,
  1223. many of which extended the file format.
  1224. John Gilmore's
  1225. .Nm pdtar
  1226. public-domain implementation (circa November, 1987)
  1227. was quite influential, and formed the basis of GNU tar.
  1228. GNU tar was included as the standard system tar
  1229. in
  1230. .Fx
  1231. beginning with
  1232. .Fx 1.0 ,
  1233. but was replaced by Tim Kientzle's
  1234. .Nm bsdtar
  1235. utility and
  1236. .Xr libarchive 3
  1237. library in
  1238. .Fx 5.3 .
  1239. .Pp
  1240. .Nm
  1241. is built around
  1242. .Nm bsdtar
  1243. and
  1244. .Xr libarchive 3 .
  1245. .Sh BUGS
  1246. This program follows
  1247. .St -p1003.1-96
  1248. for the definition of the
  1249. .Fl l
  1250. option to
  1251. .Xr tar 5 .
  1252. Note that GNU tar prior to version 1.15 treated
  1253. .Fl l
  1254. as a synonym for the
  1255. .Fl -one-file-system
  1256. option.
  1257. .Pp
  1258. To archive a file called
  1259. .Pa @foo ,
  1260. .Pa @@foo ,
  1261. or
  1262. .Pa -foo
  1263. you must specify it as
  1264. .Pa ./@foo ,
  1265. .Pa ./@@foo ,
  1266. or
  1267. .Pa ./-foo ,
  1268. respectively.
  1269. .Pp
  1270. In create mode, a leading
  1271. .Pa ./
  1272. is always removed.
  1273. A leading
  1274. .Pa /
  1275. is stripped unless the
  1276. .Fl P
  1277. option is specified.
  1278. .Pp
  1279. Hard link information may be lost if an archive file which is included via the
  1280. .Cm @ Ns Pa archive-file
  1281. option is in a non-"tar" format.
  1282. (This is a consequence of the incompatible ways that different archive
  1283. formats store hardlink information.)
  1284. .Pp
  1285. There are alternative long options for many of the short options that
  1286. are deliberately not documented.
  1287. .Pp
  1288. The limit specified by a
  1289. .Fl -maxbw
  1290. option is not strictly enforced;
  1291. in particular, due to the need to cleanly terminate an archive, the
  1292. amount of bandwidth used may slightly exceed the limit.
  1293. .Pp
  1294. If
  1295. .Nm
  1296. is run with standard input, standard output, and standard error
  1297. redirected and inside a chroot where terminal devices are not
  1298. exposed, \&^Q will not be mapped to SIGQUIT and will consequently not
  1299. trigger the truncation of the current archive.