summaryrefslogtreecommitdiff
path: root/Documentation/btrfs-send.8
blob: 1a29bfa05ab5fd9d223afe73195e32bfe2435d1f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
'\" t
.\"     Title: btrfs-send
.\"    Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author]
.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
.\"      Date: 12/05/2018
.\"    Manual: Btrfs Manual
.\"    Source: Btrfs v4.19.1
.\"  Language: English
.\"
.TH "BTRFS\-SEND" "8" "12/05/2018" "Btrfs v4\&.19\&.1" "Btrfs Manual"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el       .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
btrfs-send \- generate a stream of changes between two subvolume snapshots
.SH "SYNOPSIS"
.sp
\fBbtrfs send\fR [\-ve] [\-p \fI<parent>\fR] [\-c \fI<clone\-src>\fR] [\-f \fI<outfile>\fR] \fI<subvol>\fR [\fI<subvol>\fR\&...]
.SH "DESCRIPTION"
.sp
This command will generate a stream of instructions that describe changes between two subvolume snapshots\&. The stream can be consumed by the \fBbtrfs receive\fR command to replicate the sent snapshot on a different filesystem\&. The command operates in two modes: full and incremental\&.
.sp
All snapshots involved in one send command must be read\-only, and this status cannot be changed as long as there\(cqs a running send operation that uses the snapshot\&.
.sp
In the full mode, the entire snapshot data and metadata will end up in the stream\&.
.sp
In the incremental mode (options \fI\-p\fR and \fI\-c\fR), previously sent snapshots that are available on both the sending and receiving side can be used to reduce the amount of information that has to be sent to reconstruct the sent snapshot on a different filesystem\&.
.sp
The \fI\-p \fR\fI\fI<parent>\fR\fR option can be omitted when \fI\-c \fR\fI\fI<clone\-src>\fR\fR options are given, in which case \fBbtrfs send\fR will determine a suitable parent from among the clone sources\&.
.sp
You must not specify clone sources unless you guarantee that these snapshots are exactly in the same state on both sides\(emboth for the sender and the receiver\&.
.sp
\fBOptions\fR
.PP
\-e
.RS 4
if sending multiple subvolumes at once, use the new format and omit the
\fIend cmd\fR
marker in the stream separating the subvolumes
.RE
.PP
\-p \fI<parent>\fR
.RS 4
send an incremental stream from
\fIparent\fR
to
\fIsubvol\fR
.RE
.PP
\-c \fI<clone\-src>\fR
.RS 4
use this snapshot as a clone source for an incremental send (multiple allowed)
.RE
.PP
\-f \fI<outfile>\fR
.RS 4
output is normally written to standard output so it can be, for example, piped to btrfs receive\&. Use this option to write it to a file instead\&.
.RE
.PP
\-\-no\-data
.RS 4
send in
\fINO_FILE_DATA\fR
mode
.sp
The output stream does not contain any file data and thus cannot be used to transfer changes\&. This mode is faster and is useful to show the differences in metadata\&.
.RE
.PP
\-v|\-\-verbose
.RS 4
enable verbose output, print generated commands in a readable form, (each occurrence of this option increases the verbosity level)
.RE
.PP
\-q|\-\-quiet
.RS 4
suppress all messages except errors
.RE
.SH "EXIT STATUS"
.sp
\fBbtrfs send\fR returns a zero exit status if it succeeds\&. Non zero is returned in case of failure\&.
.SH "AVAILABILITY"
.sp
\fBbtrfs\fR is part of btrfs\-progs\&. Please refer to the btrfs wiki \m[blue]\fBhttp://btrfs\&.wiki\&.kernel\&.org\fR\m[] for further details\&.
.SH "SEE ALSO"
.sp
\fBmkfs\&.btrfs\fR(8), \fBbtrfs\-receive\fR(8)