From: Eric Blake <eblake@redhat.com>
To: qemu-devel@nongnu.org
Cc: qemu-block@nongnu.org, vsementsov@virtuozzo.com,
pbonzini@redhat.com, kwolf@redhat.com,
Max Reitz <mreitz@redhat.com>
Subject: [Qemu-devel] [PATCH v2 2.5/7] fixup! nbd-client: Refuse read-only client with BDRV_O_RDWR
Date: Wed, 8 Nov 2017 16:23:37 -0600 [thread overview]
Message-ID: <20171108222337.12400-1-eblake@redhat.com> (raw)
In-Reply-To: <20171108215703.9295-3-eblake@redhat.com>
...
Fix several iotests to comply with the new behavior (since
qemu-nbd of an internal snapshot, as well as nbd-server-add over QMP,
default to a read-only export, we must tell blockdev-add/qemu-io to
set up a read-only client).
Signed-off-by: Eric Blake <eblake@redhat.com>
---
Will squash when applying this series to the NBD queue.
---
tests/qemu-iotests/058 | 8 ++++----
tests/qemu-iotests/140 | 4 ++--
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/058 b/tests/qemu-iotests/058
index 2253c6a6d1..5eb8784669 100755
--- a/tests/qemu-iotests/058
+++ b/tests/qemu-iotests/058
@@ -117,15 +117,15 @@ _export_nbd_snapshot sn1
echo
echo "== verifying the exported snapshot with patterns, method 1 =="
-$QEMU_IO_NBD -c 'read -P 0xa 0x1000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
-$QEMU_IO_NBD -c 'read -P 0xb 0x2000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
+$QEMU_IO_NBD -r -c 'read -P 0xa 0x1000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
+$QEMU_IO_NBD -r -c 'read -P 0xb 0x2000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
_export_nbd_snapshot1 sn1
echo
echo "== verifying the exported snapshot with patterns, method 2 =="
-$QEMU_IO_NBD -c 'read -P 0xa 0x1000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
-$QEMU_IO_NBD -c 'read -P 0xb 0x2000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
+$QEMU_IO_NBD -r -c 'read -P 0xa 0x1000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
+$QEMU_IO_NBD -r -c 'read -P 0xb 0x2000 0x1000' "$nbd_snapshot_img" | _filter_qemu_io
$QEMU_IMG convert "$TEST_IMG" -l sn1 -O qcow2 "$converted_image"
diff --git a/tests/qemu-iotests/140 b/tests/qemu-iotests/140
index f89d0d6789..a8fc95145c 100755
--- a/tests/qemu-iotests/140
+++ b/tests/qemu-iotests/140
@@ -78,7 +78,7 @@ _send_qemu_cmd $QEMU_HANDLE \
'arguments': { 'device': 'drv' }}" \
'return'
-$QEMU_IO_PROG -f raw -c 'read -P 42 0 64k' \
+$QEMU_IO_PROG -f raw -r -c 'read -P 42 0 64k' \
"nbd+unix:///drv?socket=$TEST_DIR/nbd" 2>&1 \
| _filter_qemu_io | _filter_nbd
@@ -87,7 +87,7 @@ _send_qemu_cmd $QEMU_HANDLE \
'arguments': { 'device': 'drv' }}" \
'return'
-$QEMU_IO_PROG -f raw -c close \
+$QEMU_IO_PROG -f raw -r -c close \
"nbd+unix:///drv?socket=$TEST_DIR/nbd" 2>&1 \
| _filter_qemu_io | _filter_nbd
--
2.13.6
next prev parent reply other threads:[~2017-11-08 22:23 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-08 21:56 [Qemu-devel] [PATCH v2 0/7] various NBD fixes for 2.11 Eric Blake
2017-11-08 21:56 ` [Qemu-devel] [PATCH v2 1/7] nbd-client: Fix error message typos Eric Blake
2017-11-09 8:58 ` Vladimir Sementsov-Ogievskiy
2017-11-09 14:43 ` Eric Blake
2017-11-08 21:56 ` [Qemu-devel] [PATCH v2 2/7] nbd-client: Refuse read-only client with BDRV_O_RDWR Eric Blake
2017-11-08 22:07 ` Eric Blake
2017-11-08 22:23 ` Eric Blake [this message]
2017-11-09 9:05 ` [Qemu-devel] [PATCH v2 2.5/7] fixup! " Vladimir Sementsov-Ogievskiy
2017-11-09 9:04 ` [Qemu-devel] [PATCH v2 2/7] " Vladimir Sementsov-Ogievskiy
2017-11-08 21:56 ` [Qemu-devel] [PATCH v2 3/7] nbd/client: Nicer trace of structured reply Eric Blake
2017-11-09 9:10 ` Vladimir Sementsov-Ogievskiy
2017-11-08 21:57 ` [Qemu-devel] [PATCH v2 4/7] nbd: Fix struct name for structured reads Eric Blake
2017-11-09 9:13 ` Vladimir Sementsov-Ogievskiy
2017-11-08 21:57 ` [Qemu-devel] [PATCH v2 5/7] nbd-client: Short-circuit 0-length operations Eric Blake
2017-11-09 9:20 ` Vladimir Sementsov-Ogievskiy
2017-11-09 14:44 ` Eric Blake
2017-11-08 21:57 ` [Qemu-devel] [PATCH v2 6/7] nbd-client: Stricter enforcing of structured reply spec Eric Blake
2017-11-09 9:37 ` Vladimir Sementsov-Ogievskiy
2017-11-09 14:45 ` Eric Blake
2017-11-08 21:57 ` [Qemu-devel] [PATCH v2 7/7] nbd/server: Fix structured read of length 0 Eric Blake
2017-11-09 9:43 ` Vladimir Sementsov-Ogievskiy
2017-11-08 22:24 ` [Qemu-devel] [PATCH v2 0/7] various NBD fixes for 2.11 no-reply
2017-11-08 23:05 ` Eric Blake
2017-11-09 5:34 ` Fam Zheng
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171108222337.12400-1-eblake@redhat.com \
--to=eblake@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=vsementsov@virtuozzo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).