qemu/docs/interop
Eric Blake 58a6fdcc9e nbd/server: Allow MULTI_CONN for shared writable exports
According to the NBD spec, a server that advertises
NBD_FLAG_CAN_MULTI_CONN promises that multiple client connections will
not see any cache inconsistencies: when properly separated by a single
flush, actions performed by one client will be visible to another
client, regardless of which client did the flush.

We always satisfy these conditions in qemu - even when we support
multiple clients, ALL clients go through a single point of reference
into the block layer, with no local caching.  The effect of one client
is instantly visible to the next client.  Even if our backend were a
network device, we argue that any multi-path caching effects that
would cause inconsistencies in back-to-back actions not seeing the
effect of previous actions would be a bug in that backend, and not the
fault of caching in qemu.  As such, it is safe to unconditionally
advertise CAN_MULTI_CONN for any qemu NBD server situation that
supports parallel clients.

Note, however, that we don't want to advertise CAN_MULTI_CONN when we
know that a second client cannot connect (for historical reasons,
qemu-nbd defaults to a single connection while nbd-server-add and QMP
commands default to unlimited connections; but we already have
existing means to let either style of NBD server creation alter those
defaults).  This is visible by no longer advertising MULTI_CONN for
'qemu-nbd -r' without -e, as in the iotest nbd-qemu-allocation.

The harder part of this patch is setting up an iotest to demonstrate
behavior of multiple NBD clients to a single server.  It might be
possible with parallel qemu-io processes, but I found it easier to do
in python with the help of libnbd, and help from Nir and Vladimir in
writing the test.

Signed-off-by: Eric Blake <eblake@redhat.com>
Suggested-by: Nir Soffer <nsoffer@redhat.com>
Suggested-by: Vladimir Sementsov-Ogievskiy <v.sementsov-og@mail.ru>
Message-Id: <20220512004924.417153-3-eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2022-05-12 13:10:52 +02:00
..
barrier.rst docs: Move the protocol part of barrier.txt into interop 2021-08-02 12:55:51 +01:00
bitmaps.rst docs/interop/bitmaps: use blockdev-backup 2021-11-09 18:20:47 +01:00
dbus-display.rst docs: add dbus-display documentation 2021-12-21 10:50:21 +04:00
dbus-vmstate.rst docs: move D-Bus VMState documentation to source XML 2021-12-21 10:50:21 +04:00
dbus.rst docs: add dbus-display documentation 2021-12-21 10:50:21 +04:00
firmware.json docs: expand firmware descriptor to allow flash without NVRAM 2022-02-16 18:53:26 +00:00
index.rst docs: reSTify virtio-balloon-stats documentation and move to docs/interop 2022-01-07 19:30:13 -05:00
live-block-operations.rst qapi: deprecate drive-backup 2021-11-09 18:21:19 +01:00
nbd.txt nbd/server: Allow MULTI_CONN for shared writable exports 2022-05-12 13:10:52 +02:00
parallels.txt parallels.txt: fix bitmap L1 table description 2021-03-08 14:56:54 +01:00
pr-helper.rst global: Squash 'the the' 2019-11-06 17:19:40 +01:00
prl-xml.txt docs/interop/prl-xml: description of Parallels Disk format 2018-01-22 14:02:33 +00:00
qcow2.txt docs: Spell QEMU all caps 2021-11-19 10:16:58 +01:00
qed_spec.txt
qemu-ga-ref.rst docs: Remove stale TODO comments about license and version 2021-08-02 11:42:38 +01:00
qemu-ga.rst qemu-ga: document vsock-listen in the man page 2020-03-24 11:32:19 -05:00
qemu-qmp-ref.rst docs: Remove stale TODO comments about license and version 2021-08-02 11:42:38 +01:00
qemu-storage-daemon-qmp-ref.rst docs: Remove stale TODO comments about license and version 2021-08-02 11:42:38 +01:00
qmp-intro.txt docs: update to show preferred boolean syntax for -chardev 2021-02-25 14:14:33 +01:00
qmp-spec.txt docs/interop/qmp-spec: Document the request queue limit 2021-02-04 13:20:29 +01:00
vhost-user-gpu.rst docs: Move licence/copyright from HTML output to rST comments 2021-08-02 11:42:38 +01:00
vhost-user.json configure: Improve OpenGL dependency detections 2021-03-04 09:35:30 +01:00
vhost-user.rst docs/vhost-user: Clarifications for VHOST_USER_ADD/REM_MEM_REG 2022-05-04 15:55:23 +02:00
vhost-vdpa.rst vhost-vdpa: introduce vhost-vdpa backend 2020-07-07 07:59:51 -04:00
virtio-balloon-stats.rst docs: reSTify virtio-balloon-stats documentation and move to docs/interop 2022-01-07 19:30:13 -05:00
vnc-ledstate-Pseudo-encoding.txt