btrfs-progs: docs: update note about device deletion
[platform/upstream/btrfs-progs.git] / Documentation / btrfs-send.asciidoc
1 btrfs-send(8)
2 =============
3
4 NAME
5 ----
6 btrfs-send - generate a stream of changes between two subvolume snapshots
7
8 SYNOPSIS
9 --------
10 *btrfs send* [-ve] [-p <parent>] [-c <clone-src>] [-f <outfile>] <subvol> [<subvol>...]
11
12 DESCRIPTION
13 -----------
14
15 This command will generate a stream of instructions that describe changes
16 between two subvolume snapshots. The stream can be consumed by the *btrfs
17 receive* command to replicate the sent snapshot on a different filesystem.
18 The command operates in two modes: full and incremental.
19
20 All snapshots involved in one send command must be read-only, and this status
21 cannot be changed as long as there's a running send operation that uses the
22 snapshot.
23
24 In the full mode, the entire snapshot data and metadata will end up in the
25 stream.
26
27 In the incremental mode (options '-p' and '-c'), previously sent snapshots that
28 are available on both the sending and receiving side can be used to reduce the
29 amount of information that has to be sent to reconstruct the sent snapshot on a
30 different filesystem.
31
32 It is allowed to omit the '-p <parent>' option when '-c <clone-src>' options
33 are given, in which case *btrfs send* will determine a suitable parent among the
34 clone sources itself.
35
36 You must not specify clone sources unless you guarantee that these snapshots
37 are exactly in the same state on both sides, the sender and the receiver.
38
39 `Options`
40
41 -e::
42 if sending multiple subvolumes at once, use the new format and omit the
43 'end cmd' marker in the stream separating the subvolumes
44 -p <parent>::
45 send an incremental stream from 'parent' to 'subvol'
46 -c <clone-src>::
47 use this snapshot as a clone source for an incremental send (multiple allowed)
48 -f <outfile>::
49 output is normally written to standard output so it can be, for example, piped
50 to btrfs receive. Use this option to write it to a file instead.
51 --no-data::
52 send in 'NO_FILE_DATA' mode
53 +
54 The output stream does not contain any file
55 data and thus cannot be used to transfer changes. This mode is faster and
56 useful to show the differences in metadata.
57
58 -v|--verbose::
59 enable verbose output, print generated commands in a readable form, (each
60 occurrence of this option increases the verbosity level)
61 -q|--quiet::
62 suppress all messages except errors
63
64 EXIT STATUS
65 -----------
66 *btrfs send* returns a zero exit status if it succeeds. Non zero is
67 returned in case of failure.
68
69 AVAILABILITY
70 ------------
71 *btrfs* is part of btrfs-progs.
72 Please refer to the btrfs wiki http://btrfs.wiki.kernel.org for
73 further details.
74
75 SEE ALSO
76 --------
77 `mkfs.btrfs`(8),
78 `btrfs-receive`(8)