MAINTAINERS: PPC: Remove myself
[qemu.git] / docs / interop / nbd.txt
blob77b5f459111f2d952264c1e4171441b1404435ad
1 Qemu supports the NBD protocol, and has an internal NBD client (see
2 block/nbd.c), an internal NBD server (see blockdev-nbd.c), and an
3 external NBD server tool (see qemu-nbd.c). The common code is placed
4 in nbd/*.
6 The NBD protocol is specified here:
7 https://github.com/NetworkBlockDevice/nbd/blob/master/doc/proto.md
9 The following paragraphs describe some specific properties of NBD
10 protocol realization in Qemu.
12 = Metadata namespaces =
14 Qemu supports the "base:allocation" metadata context as defined in the
15 NBD protocol specification, and also defines an additional metadata
16 namespace "qemu".
19 == "qemu" namespace ==
21 The "qemu" namespace currently contains only one type of context,
22 related to exposing the contents of a dirty bitmap alongside the
23 associated disk contents.  That context has the following form:
25     qemu:dirty-bitmap:<dirty-bitmap-export-name>
27 Each dirty-bitmap metadata context defines only one flag for extents
28 in reply for NBD_CMD_BLOCK_STATUS:
30     bit 0: NBD_STATE_DIRTY, means that the extent is "dirty"
32 For NBD_OPT_LIST_META_CONTEXT the following queries are supported
33 in addition to "qemu:dirty-bitmap:<dirty-bitmap-export-name>":
35 * "qemu:" - returns list of all available metadata contexts in the
36             namespace.
37 * "qemu:dirty-bitmap:" - returns list of all available dirty-bitmap
38                          metadata contexts.