Debian Codegraph @

upstream/debian-trixie/man8/btrfs-send.8

raw
1 .\" Man page generated from reStructuredText.
2 .
3 .
4 .nr rst2man-indent-level 0
5 .
6 .de1 rstReportMargin
7 \\$1 \\n[an-margin]
8 level \\n[rst2man-indent-level]
9 level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
10 -
11 \\n[rst2man-indent0]
12 \\n[rst2man-indent1]
13 \\n[rst2man-indent2]
14 ..
15 .de1 INDENT
16 .\" .rstReportMargin pre:
17 . RS \\$1
18 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
19 . nr rst2man-indent-level +1
20 .\" .rstReportMargin post:
21 ..
22 .de UNINDENT
23 . RE
24 .\" indent \\n[an-margin]
25 .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
26 .nr rst2man-indent-level -1
27 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
28 .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
29 ..
30 .TH "BTRFS-SEND" "8" "May 18, 2026" "7.0" "BTRFS"
31 .SH NAME
32 btrfs-send \- generate a stream of changes between two subvolume snapshots
33 .SH SYNOPSIS
34 .sp
35 \fBbtrfs send\fP [\-ve] [\-p <parent>] [\-c <clone\-src>] [\-f <outfile>] <subvol> [<subvol>...]
36 .SH DESCRIPTION
37 .sp
38 This command will generate a stream of instructions that describe changes
39 between two subvolume snapshots. The stream can be consumed by the \fBbtrfs receive\fP
40 command to replicate the sent snapshot on a different filesystem.
41 The command operates in two modes: full and incremental.
42 .sp
43 All snapshots involved in one send command must be read\-only, and this status
44 cannot be changed as long as there\(aqs a running send operation that uses the
45 snapshot. Read\-only mount of the subvolume is not sufficient, there\(aqs no way to
46 guarantee that there won\(aqt be any other writable mount of the same subvolume
47 that would potentially write while send would be running.
48 .sp
49 In the full mode, the entire snapshot data and metadata will end up in the
50 stream.
51 .sp
52 In the incremental mode (options \fI\-p\fP and \fI\-c\fP), previously sent snapshots that
53 are available on both the sending and receiving side can be used to reduce the
54 amount of information that has to be sent to reconstruct the sent snapshot on a
55 different filesystem.
56 .sp
57 The \fI\-p <parent>\fP option can be omitted when \fI\-c <clone\-src>\fP options are
58 given, in which case \fBbtrfs send\fP will determine a suitable parent from among
59 the clone sources.
60 .sp
61 You must not specify clone sources unless you guarantee that these snapshots
62 are exactly in the same state on both sides\-\-both for the sender and the
63 receiver. For implications of changed read\-write status of a received snapshot
64 please see section \fISUBVOLUME FLAGS\fP in \fI\%btrfs\-subvolume(8)\fP\&.
65 .sp
66 \fBOptions\fP
67 .INDENT 0.0
68 .TP
69 .B \-e
70 if sending multiple subvolumes at once, use the new format and omit the
71 \fIend cmd\fP marker in the stream separating the subvolumes
72 .TP
73 .BI \-p \ <parent>
74 send an incremental stream from \fIparent\fP to \fIsubvol\fP
75 .TP
76 .BI \-c \ <clone\-src>
77 use this snapshot as a clone source for an incremental send (multiple
78 allowed)
79 .TP
80 .BI \-f \ <outfile>
81 output is normally written to standard output so it can be, for
82 example, piped to btrfs receive. Use this option to write it to a file
83 instead.
84 .TP
85 .B \-\-no\-data
86 send in \fINO_FILE_DATA\fP mode
87 .sp
88 The output stream does not contain any file data and thus cannot be
89 used to transfer changes. This mode is faster and is useful to show the
90 differences in metadata.
91 .TP
92 .BI \-\-proto \ <N>
93 use send protocol version N
94 .sp
95 The default is 1, which was the original protocol version. Version 2
96 encodes file data slightly more efficiently; it is also required for
97 sending compressed data directly (see \fI\-\-compressed\-data\fP). Version 2
98 requires at least btrfs\-progs 6.0 on both the sender and receiver and
99 at least Linux 6.0 on the sender. Passing 0 means to use the highest
100 version supported by the running kernel.
101 .TP
102 .B \-\-compressed\-data
103 send data that is compressed on the filesystem directly without
104 decompressing it
105 .sp
106 If the receiver supports the \fIBTRFS_IOC_ENCODED_WRITE\fP ioctl (added in
107 Linux 6.0), it can also write it directly without decompressing it.
108 Otherwise, the receiver will fall back to decompressing it and writing
109 it normally.
110 .sp
111 This requires protocol version 2 or higher. If \fI\-\-proto\fP was not used,
112 then \fI\-\-compressed\-data\fP implies \fI\-\-proto 2\fP\&.
113 .UNINDENT
114 .INDENT 0.0
115 .TP
116 .B \-q|\-\-quiet
117 (deprecated) alias for global \fI\-q\fP option
118 .TP
119 .B \-v|\-\-verbose
120 (deprecated) alias for global \fI\-v\fP option
121 .UNINDENT
122 .sp
123 \fBGlobal options\fP
124 .INDENT 0.0
125 .TP
126 .B \-q|\-\-quiet
127 suppress all messages except errors
128 .TP
129 .B \-v|\-\-verbose
130 increase output verbosity, print generated commands in a readable form
131 .UNINDENT
132 .SH EXIT STATUS
133 .sp
134 \fBbtrfs send\fP returns a zero exit status if it succeeds. Non zero is
135 returned in case of failure.
136 .SH AVAILABILITY
137 .sp
138 \fBbtrfs\fP is part of btrfs\-progs. Please refer to the documentation at
139 \X'tty: link https://btrfs.readthedocs.io'\fI\%https://btrfs.readthedocs.io\fP\X'tty: link'\&.
140 .SH SEE ALSO
141 .sp
142 \fI\%btrfs\-receive(8)\fP,
143 \fI\%btrfs\-subvolume(8)\fP,
144 \fI\%mkfs.btrfs(8)\fP
145 .\" Generated by docutils manpage writer.
146 .