1
0
Fork 0
mirror of https://github.com/borgbackup/borg.git synced 2024-12-29 11:16:43 +00:00
borg/docs/man/borg-export-tar.1

149 lines
4.1 KiB
Groff
Raw Normal View History

2017-05-16 22:09:41 +00:00
.\" Man page generated from reStructuredText.
.
2017-11-05 22:09:39 +00:00
.TH BORG-EXPORT-TAR 1 "2017-11-05" "" "borg backup tool"
2017-05-16 22:09:41 +00:00
.SH NAME
borg-export-tar \- Export archive contents as a tarball
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.SH SYNOPSIS
.sp
2017-08-27 20:18:45 +00:00
borg [common options] export\-tar [options] ARCHIVE FILE [PATH...]
2017-05-16 22:09:41 +00:00
.SH DESCRIPTION
.sp
This command creates a tarball from an archive.
.sp
When giving \(aq\-\(aq as the output FILE, Borg will write a tar stream to standard output.
.sp
2017-06-18 10:13:28 +00:00
By default (\fB\-\-tar\-filter=auto\fP) Borg will detect whether the FILE should be compressed
2017-05-16 22:09:41 +00:00
based on its file extension and pipe the tarball through an appropriate filter
before writing it to FILE:
.INDENT 0.0
.IP \(bu 2
\&.tar.gz: gzip
.IP \(bu 2
\&.tar.bz2: bzip2
.IP \(bu 2
\&.tar.xz: xz
.UNINDENT
.sp
2017-06-18 10:13:28 +00:00
Alternatively a \fB\-\-tar\-filter\fP program may be explicitly specified. It should
2017-05-16 22:09:41 +00:00
read the uncompressed tar stream from stdin and write a compressed/filtered
tar stream to stdout.
.sp
The generated tarball uses the GNU tar format.
.sp
export\-tar is a lossy conversion:
BSD flags, ACLs, extended attributes (xattrs), atime and ctime are not exported.
Timestamp resolution is limited to whole seconds, not the nanosecond resolution
otherwise supported by Borg.
.sp
2017-06-18 10:13:28 +00:00
A \fB\-\-sparse\fP option (as found in borg extract) is not supported.
2017-05-16 22:09:41 +00:00
.sp
By default the entire archive is extracted but a subset of files and directories
can be selected by passing a list of \fBPATHs\fP as arguments.
The file selection can further be restricted by using the \fB\-\-exclude\fP option.
.sp
See the output of the "borg help patterns" command for more help on exclude patterns.
.sp
\fB\-\-progress\fP can be slower than no progress display, since it makes one additional
pass over the archive metadata.
.SH OPTIONS
.sp
See \fIborg\-common(1)\fP for common options of Borg commands.
.SS arguments
.INDENT 0.0
.TP
.B ARCHIVE
archive to export
.TP
.B FILE
output tar file. "\-" to write to stdout instead.
.TP
.B PATH
paths to extract; patterns are supported
.UNINDENT
.SS optional arguments
.INDENT 0.0
.TP
.B \-\-tar\-filter
filter program to pipe data through
.TP
.B \-\-list
output verbose list of items (files, dirs, ...)
2017-08-27 20:18:45 +00:00
.UNINDENT
.SS Exclusion options
.INDENT 0.0
2017-05-16 22:09:41 +00:00
.TP
.BI \-e \ PATTERN\fP,\fB \ \-\-exclude \ PATTERN
exclude paths matching PATTERN
.TP
.BI \-\-exclude\-from \ EXCLUDEFILE
read exclude patterns from EXCLUDEFILE, one per line
.TP
.BI \-\-pattern \ PATTERN
2017-06-18 10:13:28 +00:00
experimental: include/exclude paths matching PATTERN
2017-05-16 22:09:41 +00:00
.TP
.BI \-\-patterns\-from \ PATTERNFILE
2017-06-18 10:13:28 +00:00
experimental: read include/exclude patterns from PATTERNFILE, one per line
2017-05-16 22:09:41 +00:00
.TP
.BI \-\-strip\-components \ NUMBER
2017-08-27 20:18:45 +00:00
Remove the specified number of leading path elements. Paths with fewer elements will be silently skipped.
2017-05-16 22:09:41 +00:00
.UNINDENT
.SH EXAMPLES
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
# export as uncompressed tar
$ borg export\-tar /path/to/repo::Monday Monday.tar
# exclude some types, compress using gzip
$ borg export\-tar /path/to/repo::Monday Monday.tar.gz \-\-exclude \(aq*.so\(aq
# use higher compression level with gzip
$ borg export\-tar testrepo::linux \-\-tar\-filter="gzip \-9" Monday.tar.gz
# export a gzipped tar, but instead of storing it on disk,
# upload it to a remote site using curl.
$ borg export\-tar ... \-\-tar\-filter="gzip" \- | curl \-\-data\-binary @\- https://somewhere/to/POST
2017-08-27 20:18:45 +00:00
# remote extraction via "tarpipe"
$ borg export\-tar /path/to/repo::Monday \- | ssh somewhere "cd extracted; tar x"
2017-05-16 22:09:41 +00:00
.ft P
.fi
.UNINDENT
.UNINDENT
.SH SEE ALSO
.sp
\fIborg\-common(1)\fP
.SH AUTHOR
The Borg Collective
.\" Generated by docutils manpage writer.
.