From nobody Mon Nov 23 05:00:23 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 17907746678461007.5342712714593; Wed, 30 Sep 2026 06:24:27 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xBuGa-0006kE-Vq; Wed, 30 Sep 2026 09:22:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuG3-0006h4-7p; Wed, 30 Sep 2026 09:22:05 -0400 Received: from proxmox-new.maurer-it.com ([94.136.29.106]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuFx-0004IB-W6; Wed, 30 Sep 2026 09:22:00 -0400 Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 673F9455BE; Wed, 30 Sep 2026 15:21:46 +0200 (CEST) From: Fiona Ebner To: qemu-devel@nongnu.org Cc: qemu-block@nongnu.org, hreitz@redhat.com, kwolf@redhat.com, qemu-stable@nongnu.org Subject: [PATCH qemu 1/4] iotests: add test cases for failing flush after qemu-img convert Date: Wed, 30 Sep 2026 15:19:22 +0200 Message-ID: <20260930132140.2342574-2-f.ebner@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260930132140.2342574-1-f.ebner@proxmox.com> References: <20260930132140.2342574-1-f.ebner@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1790774505317 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=94.136.29.106; envelope-from=f.ebner@proxmox.com; helo=proxmox-new.maurer-it.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1790774668806158500 Content-Type: text/plain; charset="utf-8" In preparation to add more checks in the following commits and show how the behavior changes. Signed-off-by: Fiona Ebner Reviewed-by: Eric Blake --- tests/qemu-iotests/122 | 33 +++++++++++++++++++++++++++++++++ tests/qemu-iotests/122.out | 14 ++++++++++++++ 2 files changed, 47 insertions(+) diff --git a/tests/qemu-iotests/122 b/tests/qemu-iotests/122 index be0f6b79e5..488649f1bd 100755 --- a/tests/qemu-iotests/122 +++ b/tests/qemu-iotests/122 @@ -334,6 +334,39 @@ echo $QEMU_IMG convert -O $IMGFMT -o preallocation=3Dmetadata -n \ "$TEST_IMG" "$TEST_IMG".orig && echo "unexpected success" =20 +echo +echo "=3D=3D=3D failing flush after convert with default ('unsafe') cache = mode =3D=3D=3D" +echo + +TEST_IMG=3D"$TEST_IMG".orig _make_test_img 1M +TEST_IMG=3D"$TEST_IMG" _make_test_img 1M + +$QEMU_IO -c "write -P 42 0 1M" "$TEST_IMG".orig | _filter_qemu_io + +target_fails_flush=3D"json:{ + 'driver': '$IMGFMT', + 'file': { + 'driver': 'blkdebug', + 'inject-error': [{ + 'event': 'flush_to_disk' + }], + 'image': { + 'driver': 'file', + 'filename': '$TEST_IMG' + } + } +}" + +$QEMU_IMG convert -f $IMGFMT -O $IMGFMT -n "$TEST_IMG".orig "$target_fails= _flush" +echo "qemu-img convert exited with status $?" + +echo +echo "=3D=3D=3D failing flush after convert with 'writeback' cache mode = =3D=3D=3D" +echo + +$QEMU_IMG convert -t writeback -f $IMGFMT -O $IMGFMT -n "$TEST_IMG".orig "= $target_fails_flush" +echo "qemu-img convert exited with status $?" + # success, all done echo '*** done' rm -f $seq.full diff --git a/tests/qemu-iotests/122.out b/tests/qemu-iotests/122.out index 6a1aa3fe2b..f3e28f33bc 100644 --- a/tests/qemu-iotests/122.out +++ b/tests/qemu-iotests/122.out @@ -256,4 +256,18 @@ Formatting 'TEST_DIR/t.IMGFMT.orig', fmt=3DIMGFMT size= =3D67108864 =3D=3D=3D -n incompatible with -o =3D=3D=3D =20 qemu-img: -o has no effect when skipping image creation + +=3D=3D=3D failing flush after convert with default ('unsafe') cache mode = =3D=3D=3D + +Formatting 'TEST_DIR/t.IMGFMT.orig', fmt=3DIMGFMT size=3D1048576 +Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1048576 +wrote 1048576/1048576 bytes at offset 0 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +qemu-img convert exited with status 0 + +=3D=3D=3D failing flush after convert with 'writeback' cache mode =3D=3D= =3D + +qemu-img: Failed to flush the L2 table cache: Input/output error +qemu-img: Failed to flush the refcount block cache: Input/output error +qemu-img convert exited with status 0 *** done --=20 2.47.3 From nobody Mon Nov 23 05:00:23 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1790774628870387.0328848262461; Wed, 30 Sep 2026 06:23:48 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xBuGd-0006ni-2l; Wed, 30 Sep 2026 09:22:39 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuG3-0006h6-8m; Wed, 30 Sep 2026 09:22:05 -0400 Received: from proxmox-new.maurer-it.com ([94.136.29.106]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuFx-0004IC-WA; Wed, 30 Sep 2026 09:22:01 -0400 Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 479DC456FD; Wed, 30 Sep 2026 15:21:46 +0200 (CEST) From: Fiona Ebner To: qemu-devel@nongnu.org Cc: qemu-block@nongnu.org, hreitz@redhat.com, kwolf@redhat.com, qemu-stable@nongnu.org Subject: [PATCH qemu 2/4] iotests.py: add filter_qemu() Date: Wed, 30 Sep 2026 15:19:23 +0200 Message-ID: <20260930132140.2342574-3-f.ebner@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260930132140.2342574-1-f.ebner@proxmox.com> References: <20260930132140.2342574-1-f.ebner@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1790774505375 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=94.136.29.106; envelope-from=f.ebner@proxmox.com; helo=proxmox-new.maurer-it.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1790774632566158500 Content-Type: text/plain; charset="utf-8" Add a filter_qemu() helper function for replacing the QEMU program name with 'QEMU_PROG' in test's log messages. Signed-off-by: Fiona Ebner Reviewed-by: Eric Blake --- tests/qemu-iotests/iotests.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 7d5a77a85e..642a160bb2 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -596,6 +596,10 @@ def filter_qemu_io(msg): return qemu_io_re.sub("X ops; XX:XX:XX.X " "(XXX YYY/sec and XXX ops/sec)", msg) =20 +qemu_re =3D re.compile(r"%s" % os.path.basename(qemu_prog)) +def filter_qemu(msg): + return qemu_re.sub("QEMU_PROG", msg) + chown_re =3D re.compile(r"chown [0-9]+:[0-9]+") def filter_chown(msg): return chown_re.sub("chown UID:GID", msg) --=20 2.47.3 From nobody Mon Nov 23 05:00:23 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 179077462939221.343719298784094; Wed, 30 Sep 2026 06:23:49 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xBuGe-0006p7-HU; Wed, 30 Sep 2026 09:22:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuGA-0006hr-QJ; Wed, 30 Sep 2026 09:22:11 -0400 Received: from proxmox-new.maurer-it.com ([94.136.29.106]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuG2-0004Ih-UD; Wed, 30 Sep 2026 09:22:08 -0400 Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id C80AB456FE; Wed, 30 Sep 2026 15:21:51 +0200 (CEST) From: Fiona Ebner To: qemu-devel@nongnu.org Cc: qemu-block@nongnu.org, hreitz@redhat.com, kwolf@redhat.com, qemu-stable@nongnu.org Subject: [PATCH qemu 3/4] block: report flush error during bdrv_close() Date: Wed, 30 Sep 2026 15:19:24 +0200 Message-ID: <20260930132140.2342574-4-f.ebner@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260930132140.2342574-1-f.ebner@proxmox.com> References: <20260930132140.2342574-1-f.ebner@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1790774505486 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=94.136.29.106; envelope-from=f.ebner@proxmox.com; helo=proxmox-new.maurer-it.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1790774630957158500 Content-Type: text/plain; charset="utf-8" Flush during bdrv_close() was introduced back in 2012 in commit 80ccf93b88 ("qemu-img: let 'qemu-img convert' flush data"). However, a failing flush was quietly ignored [0]. Report the error instead, since this could mean that the image contents are not as expected. Adapt the iotests accordingly. For all tests except '080' and 'qsd-migrate' the failures come from blkdebug configurations. For '080', the failures are also directly expected, because of invalid L1 table size and offset. For the 'qsd-migrate' test, the error happens, because the QSD node which is attached via NBD to the source VM was inactivated. [0]: Note that the errors reported for qcow2 come from qcow2_inactivate() which is only called as part of bs->drv->bdrv_close() after bdrv_flush(). In particular, adding > 'once': 'on' to the blkdebug driver in the relevant test case in the 122 iotest shows that the failure can be silent in case of qcow2 too. Signed-off-by: Fiona Ebner Reviewed-by: Eric Blake --- block.c | 13 +++- tests/qemu-iotests/026 | 10 +-- tests/qemu-iotests/026.out | 84 ++++++++++++++++++++++ tests/qemu-iotests/071 | 2 +- tests/qemu-iotests/071.out | 2 + tests/qemu-iotests/080.out | 2 + tests/qemu-iotests/098.out | 4 ++ tests/qemu-iotests/122 | 8 +-- tests/qemu-iotests/122.out | 2 + tests/qemu-iotests/244 | 2 +- tests/qemu-iotests/244.out | 1 + tests/qemu-iotests/tests/file-io-error | 2 +- tests/qemu-iotests/tests/file-io-error.out | 2 + tests/qemu-iotests/tests/qsd-migrate | 5 +- tests/qemu-iotests/tests/qsd-migrate.out | 1 + 15 files changed, 125 insertions(+), 15 deletions(-) diff --git a/block.c b/block.c index f0a6042e61..c05ad01f25 100644 --- a/block.c +++ b/block.c @@ -5162,12 +5162,23 @@ static void GRAPH_UNLOCKED bdrv_close(BlockDriverSt= ate *bs) { BdrvAioNotifier *ban, *ban_next; BdrvChild *child, *next; + int ret; =20 GLOBAL_STATE_CODE(); assert(!bs->refcnt); =20 bdrv_drained_begin(bs); /* complete I/O */ - bdrv_flush(bs); + ret =3D bdrv_flush(bs); + if (ret < 0) { + const char *name; + if (bs->filename[0]) { + name =3D bs->filename; + } else { + name =3D bdrv_get_node_name(bs); + } + error_report("Failed flush for '%s' during close: %s", name, + strerror(-ret)); + } bdrv_drain(bs); /* in case flush left pending I/O */ =20 if (bs->drv) { diff --git a/tests/qemu-iotests/026 b/tests/qemu-iotests/026 index d37e266dad..88cb4dd934 100755 --- a/tests/qemu-iotests/026 +++ b/tests/qemu-iotests/026 @@ -103,13 +103,13 @@ if [ "$event" =3D=3D "l2_update" ]; then $QEMU_IO -c "write $vmstate 0 512" "$TEST_IMG" > /dev/null 2>&1 fi =20 -$QEMU_IO -c "write $vmstate 0 128k " "$BLKDBG_TEST_IMG" | _filter_qemu_io +$QEMU_IO -c "write $vmstate 0 128k " "$BLKDBG_TEST_IMG" 2>&1 | _filter_qem= u_io | _filter_testdir =20 # l2_load is not called on allocation, so issue a second write # Reads are another path to trigger l2_load, so do a read, too if [ "$event" =3D=3D "l2_load" ]; then - $QEMU_IO -c "write $vmstate 0 128k " "$BLKDBG_TEST_IMG" | _filter_qemu= _io - $QEMU_IO -c "read $vmstate 0 128k " "$BLKDBG_TEST_IMG" | _filter_qemu_= io + $QEMU_IO -c "write $vmstate 0 128k " "$BLKDBG_TEST_IMG" 2>&1 | _filter= _qemu_io | _filter_testdir + $QEMU_IO -c "read $vmstate 0 128k " "$BLKDBG_TEST_IMG" 2>&1 | _filter_= qemu_io | _filter_testdir fi =20 _check_test_img_ignore_leaks 2>&1 | grep -v "refcount=3D1 reference=3D0" @@ -155,7 +155,7 @@ _make_test_img 1G =20 echo echo "Event: $event; errno: $errno; imm: $imm; once: $once; write $vmstate" -$QEMU_IO -c "write $vmstate 0 64M" "$BLKDBG_TEST_IMG" | _filter_qemu_io +$QEMU_IO -c "write $vmstate 0 64M" "$BLKDBG_TEST_IMG" 2>&1 | _filter_qemu_= io | _filter_testdir =20 _check_test_img_ignore_leaks 2>&1 | grep -v "refcount=3D1 reference=3D0" =20 @@ -194,7 +194,7 @@ _make_test_img 1G =20 echo echo "Event: $event; errno: $errno; imm: $imm; once: $once" -$QEMU_IO -c "write -b 0 64k" "$BLKDBG_TEST_IMG" | _filter_qemu_io +$QEMU_IO -c "write -b 0 64k" "$BLKDBG_TEST_IMG" 2>&1 | _filter_qemu_io | _= filter_testdir =20 _check_test_img_ignore_leaks 2>&1 | grep -v "refcount=3D1 reference=3D0" =20 diff --git a/tests/qemu-iotests/026.out b/tests/qemu-iotests/026.out index b998a9ac83..47bd88b1d3 100644 --- a/tests/qemu-iotests/026.out +++ b/tests/qemu-iotests/026.out @@ -15,15 +15,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D107= 3741824 =20 Event: l1_update; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: l1_update; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -39,15 +43,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D107= 3741824 =20 Event: l1_update; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: l1_update; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -127,15 +135,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: l2_update; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: l2_update; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -151,15 +163,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: l2_update; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: l2_update; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -175,15 +191,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: l2_alloc_write; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: l2_alloc_write; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -199,15 +219,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: l2_alloc_write; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: l2_alloc_write; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -223,15 +247,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: write_aio; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: write_aio; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -247,15 +275,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: write_aio; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: write_aio; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -271,15 +303,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_load; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_load; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -295,15 +331,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_load; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_load; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -319,15 +359,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_update_part; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_update_part; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -343,15 +387,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_update_part; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_update_part; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -367,15 +415,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc; errno: 5; imm: off; once: off; write qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc; errno: 5; imm: off; once: off; write -b qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -391,15 +443,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -458,15 +514,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -482,15 +542,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc_write; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc_write; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -506,15 +570,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write = -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -530,15 +598,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -554,15 +626,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1= 073741824 =20 Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write = -b qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. =20 =3D=3D=3D L1 growth tests =3D=3D=3D @@ -596,8 +672,10 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D10= 73741824 =20 Event: l1_grow_write_table; errno: 5; imm: off; once: off qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -608,8 +686,10 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D10= 73741824 =20 Event: l1_grow_write_table; errno: 28; imm: off; once: off qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -620,8 +700,10 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D10= 73741824 =20 Event: l1_grow_activate_table; errno: 5; imm: off; once: off qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error qemu-io: Failed to flush the L2 table cache: Input/output error qemu-io: Failed to flush the refcount block cache: Input/output error +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: Input/output error No errors were found on the image. Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D1073741824 =20 @@ -632,8 +714,10 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D10= 73741824 =20 Event: l1_grow_activate_table; errno: 28; imm: off; once: off qemu-io: write failed: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device qemu-io: Failed to flush the L2 table cache: No space left on device qemu-io: Failed to flush the refcount block cache: No space left on device +qemu-io: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.qcow= 2' during close: No space left on device No errors were found on the image. =20 =3D=3D=3D Avoid cluster leaks after temporary failure =3D=3D=3D diff --git a/tests/qemu-iotests/071 b/tests/qemu-iotests/071 index 83c4ce6314..8237b325ea 100755 --- a/tests/qemu-iotests/071 +++ b/tests/qemu-iotests/071 @@ -54,7 +54,7 @@ do_run_qemu() =20 run_qemu() { - do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu | _filter_qmp |= _filter_qemu_io + do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu | _filter_qmp |= _filter_qemu_io | _filter_json_filename } =20 IMG_SIZE=3D64M diff --git a/tests/qemu-iotests/071.out b/tests/qemu-iotests/071.out index f2d015d8cc..a69e6f7e50 100644 --- a/tests/qemu-iotests/071.out +++ b/tests/qemu-iotests/071.out @@ -83,8 +83,10 @@ wrote 512/512 bytes at offset 0 {"return": ""} {"return": "Error: read failed: Input/output error\r\n"} {"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event"= : "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}} +QEMU_PROG: Failed flush for 'json:{ /* filtered */ }' during close: Input/= output error QEMU_PROG: Failed to flush the L2 table cache: Input/output error QEMU_PROG: Failed to flush the refcount block cache: Input/output error +QEMU_PROG: Failed flush for 'json:{ /* filtered */ }' during close: Input/= output error {"return": {}} =20 *** done diff --git a/tests/qemu-iotests/080.out b/tests/qemu-iotests/080.out index b20c21faf6..3b2b27c5fe 100644 --- a/tests/qemu-iotests/080.out +++ b/tests/qemu-iotests/080.out @@ -67,6 +67,7 @@ qemu-img: Failed to load snapshot: Snapshot L1 table offs= et invalid qemu-img: Snapshot L1 table offset invalid qemu-img: Failed to turn zero into data clusters: Invalid argument qemu-io: write failed: Invalid argument +qemu-io: Failed flush for 'TEST_DIR/t.qcow2' during close: Invalid argument qemu-io: Failed to flush the refcount block cache: Invalid argument qemu-img: Snapshot L1 table offset invalid qemu-img: Could not apply snapshot 'test': Failed to load snapshot: Invali= d argument @@ -90,6 +91,7 @@ qemu-img: Failed to load snapshot: Snapshot L1 table too = large qemu-img: Snapshot L1 table too large qemu-img: Failed to turn zero into data clusters: File too large qemu-io: write failed: File too large +qemu-io: Failed flush for 'TEST_DIR/t.qcow2' during close: File too large qemu-io: Failed to flush the refcount block cache: File too large qemu-img: Snapshot L1 table too large qemu-img: Could not apply snapshot 'test': Failed to load snapshot: File t= oo large diff --git a/tests/qemu-iotests/098.out b/tests/qemu-iotests/098.out index 6c73dd0977..912b0290af 100644 --- a/tests/qemu-iotests/098.out +++ b/tests/qemu-iotests/098.out @@ -6,6 +6,7 @@ Formatting 'TEST_DIR/t.IMGFMT.base', fmt=3DIMGFMT size=3D67= 108864 Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D67108864 backing_file= =3DTEST_DIR/t.IMGFMT.base backing_fmt=3DIMGFMT wrote 65536/65536 bytes at offset 0 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +qemu-img: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMG= FMT' during close: Input/output error qemu-img: Failed to empty blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMGFM= T: Input/output error No errors were found on the image. =20 @@ -15,6 +16,7 @@ Formatting 'TEST_DIR/t.IMGFMT.base', fmt=3DIMGFMT size=3D= 67108864 Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D67108864 backing_file= =3DTEST_DIR/t.IMGFMT.base backing_fmt=3DIMGFMT wrote 65536/65536 bytes at offset 0 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +qemu-img: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMG= FMT' during close: Input/output error qemu-img: Failed to empty blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMGFM= T: Input/output error Leaked cluster 4 refcount=3D1 reference=3D0 Leaked cluster 5 refcount=3D1 reference=3D0 @@ -28,6 +30,7 @@ Formatting 'TEST_DIR/t.IMGFMT.base', fmt=3DIMGFMT size=3D= 67108864 Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D67108864 backing_file= =3DTEST_DIR/t.IMGFMT.base backing_fmt=3DIMGFMT wrote 65536/65536 bytes at offset 0 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +qemu-img: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMG= FMT' during close: Input/output error qemu-img: Failed to empty blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMGFM= T: Input/output error ERROR cluster 0 refcount=3D0 reference=3D1 ERROR cluster 1 refcount=3D0 reference=3D1 @@ -42,6 +45,7 @@ Formatting 'TEST_DIR/t.IMGFMT.base', fmt=3DIMGFMT size=3D= 67108864 Formatting 'TEST_DIR/t.IMGFMT', fmt=3DIMGFMT size=3D67108864 backing_file= =3DTEST_DIR/t.IMGFMT.base backing_fmt=3DIMGFMT wrote 65536/65536 bytes at offset 0 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +qemu-img: Failed flush for 'blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMG= FMT' during close: Input/output error qemu-img: Failed to empty blkdebug:TEST_DIR/blkdebug.conf:TEST_DIR/t.IMGFM= T: Input/output error ERROR cluster 0 refcount=3D0 reference=3D1 ERROR cluster 1 refcount=3D0 reference=3D1 diff --git a/tests/qemu-iotests/122 b/tests/qemu-iotests/122 index 488649f1bd..9da1246f09 100755 --- a/tests/qemu-iotests/122 +++ b/tests/qemu-iotests/122 @@ -357,15 +357,15 @@ target_fails_flush=3D"json:{ } }" =20 -$QEMU_IMG convert -f $IMGFMT -O $IMGFMT -n "$TEST_IMG".orig "$target_fails= _flush" -echo "qemu-img convert exited with status $?" +$QEMU_IMG convert -f $IMGFMT -O $IMGFMT -n "$TEST_IMG".orig "$target_fails= _flush" 2>&1 | _filter_json_filename +echo "qemu-img convert exited with status ${PIPESTATUS[0]}" =20 echo echo "=3D=3D=3D failing flush after convert with 'writeback' cache mode = =3D=3D=3D" echo =20 -$QEMU_IMG convert -t writeback -f $IMGFMT -O $IMGFMT -n "$TEST_IMG".orig "= $target_fails_flush" -echo "qemu-img convert exited with status $?" +$QEMU_IMG convert -t writeback -f $IMGFMT -O $IMGFMT -n "$TEST_IMG".orig "= $target_fails_flush" 2>&1 | _filter_json_filename +echo "qemu-img convert exited with status ${PIPESTATUS[0]}" =20 # success, all done echo '*** done' diff --git a/tests/qemu-iotests/122.out b/tests/qemu-iotests/122.out index f3e28f33bc..84283f2434 100644 --- a/tests/qemu-iotests/122.out +++ b/tests/qemu-iotests/122.out @@ -267,7 +267,9 @@ qemu-img convert exited with status 0 =20 =3D=3D=3D failing flush after convert with 'writeback' cache mode =3D=3D= =3D =20 +qemu-img: Failed flush for 'json:{ /* filtered */ }' during close: Input/o= utput error qemu-img: Failed to flush the L2 table cache: Input/output error qemu-img: Failed to flush the refcount block cache: Input/output error +qemu-img: Failed flush for 'json:{ /* filtered */ }' during close: Input/o= utput error qemu-img convert exited with status 0 *** done diff --git a/tests/qemu-iotests/244 b/tests/qemu-iotests/244 index 2a98ad58f5..ef32f8ec03 100755 --- a/tests/qemu-iotests/244 +++ b/tests/qemu-iotests/244 @@ -264,7 +264,7 @@ $QEMU_IO -c 'write 0 512' -c flush \ } } }" \ - | _filter_qemu_io + 2>&1 | _filter_qemu_io | _filter_generated_node_ids =20 result=3D${PIPESTATUS[0]} echo diff --git a/tests/qemu-iotests/244.out b/tests/qemu-iotests/244.out index c5e62146c9..81463d6f0e 100644 --- a/tests/qemu-iotests/244.out +++ b/tests/qemu-iotests/244.out @@ -134,6 +134,7 @@ Images are identical. =20 =3D=3D=3D Flushing should flush the data file =3D=3D=3D =20 +qemu-io: Failed flush for 'NODE_NAME' during close: Input/output error wrote 512/512 bytes at offset 0 512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) =20 diff --git a/tests/qemu-iotests/tests/file-io-error b/tests/qemu-iotests/te= sts/file-io-error index 0d970c102f..3885b741d9 100755 --- a/tests/qemu-iotests/tests/file-io-error +++ b/tests/qemu-iotests/tests/file-io-error @@ -94,7 +94,7 @@ echo "$output" =20 echo # This should fail, but gracefully, i.e. just print an I/O error, not cras= h. -$QEMU_IO -f file -c 'write 0 64M' "$TEST_DIR/fuse-export" | _filter_qemu_io +$QEMU_IO -f file -c 'write 0 64M' "$TEST_DIR/fuse-export" 2>&1 | _filter_q= emu_io | _filter_testdir echo =20 capture_events=3DBLOCK_EXPORT_DELETED _send_qemu_cmd $QEMU_HANDLE \ diff --git a/tests/qemu-iotests/tests/file-io-error.out b/tests/qemu-iotest= s/tests/file-io-error.out index bf8c0018ba..748ea3079c 100644 --- a/tests/qemu-iotests/tests/file-io-error.out +++ b/tests/qemu-iotests/tests/file-io-error.out @@ -22,6 +22,7 @@ QA output created by file-io-error {"return": {}} =20 qemu-io: write failed: Input/output error +qemu-io: Failed flush for 'TEST_DIR/fuse-export' during close: Input/outpu= t error =20 {'execute': 'block-export-del', 'arguments': {'id': 'exp0'}} @@ -29,5 +30,6 @@ qemu-io: write failed: Input/output error {"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event"= : "BLOCK_EXPORT_DELETED", "data": {"id": "exp0"}} {'execute': 'blockdev-del', 'arguments': {'node-name': 'node0'}} +QEMU_PROG: Failed flush for 'node0' during close: Input/output error {"return": {}} *** done diff --git a/tests/qemu-iotests/tests/qsd-migrate b/tests/qemu-iotests/test= s/qsd-migrate index d76278b576..73583dec16 100755 --- a/tests/qemu-iotests/tests/qsd-migrate +++ b/tests/qemu-iotests/tests/qsd-migrate @@ -20,7 +20,7 @@ =20 import iotests =20 -from iotests import filter_qemu_io, filter_qtest +from iotests import filter_qemu, filter_qemu_io, filter_qtest =20 iotests.script_initialize(supported_fmts=3D['qcow2', 'qed', 'raw'], supported_protocols=3D['file'], @@ -126,11 +126,12 @@ with iotests.FilePath('disk.img') as path, \ =20 iotests.log('\nDone') =20 + # NOTE: Flush during close fails here, since the QSD node was inactiva= ted. vm_src.shutdown() iotests.log('\n--- vm_src log ---') log =3D vm_src.get_log() if log: - iotests.log(log, [filter_qtest, filter_qemu_io]) + iotests.log(log, [filter_qtest, filter_qemu_io, filter_qemu]) qsd_src.stop() =20 vm_dst.shutdown() diff --git a/tests/qemu-iotests/tests/qsd-migrate.out b/tests/qemu-iotests/= tests/qsd-migrate.out index 4a5241e5d4..894b232b4a 100644 --- a/tests/qemu-iotests/tests/qsd-migrate.out +++ b/tests/qemu-iotests/tests/qsd-migrate.out @@ -47,6 +47,7 @@ read 4096/4096 bytes at offset 0 4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) read 4096/4096 bytes at offset 0 4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +QEMU_PROG: Failed flush for 'disk' during close: Operation not permitted =20 --- vm_dst log --- read 4096/4096 bytes at offset 0 --=20 2.47.3 From nobody Mon Nov 23 05:00:23 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1790774608078102.83369546320137; Wed, 30 Sep 2026 06:23:28 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xBuGb-0006nA-VO; Wed, 30 Sep 2026 09:22:38 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuG3-0006h5-7p; Wed, 30 Sep 2026 09:22:05 -0400 Received: from proxmox-new.maurer-it.com ([94.136.29.106]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xBuFx-0004ID-W1; Wed, 30 Sep 2026 09:22:01 -0400 Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id D3D144576C; Wed, 30 Sep 2026 15:21:46 +0200 (CEST) From: Fiona Ebner To: qemu-devel@nongnu.org Cc: qemu-block@nongnu.org, hreitz@redhat.com, kwolf@redhat.com, qemu-stable@nongnu.org Subject: [PATCH qemu 4/4] qemu-img: convert: flush target image after copying Date: Wed, 30 Sep 2026 15:19:25 +0200 Message-ID: <20260930132140.2342574-5-f.ebner@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260930132140.2342574-1-f.ebner@proxmox.com> References: <20260930132140.2342574-1-f.ebner@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1790774505546 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists1p.gnu.org; Received-SPF: pass client-ip=94.136.29.106; envelope-from=f.ebner@proxmox.com; helo=proxmox-new.maurer-it.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZM-MESSAGEID: 1790774610495158500 Content-Type: text/plain; charset="utf-8" With 'qemu-img convert', when using a cache mode with 'cache.no-flush =3D off', the expectation is that the data is flushed to the disk, which happens since commit 80ccf93b88 ("qemu-img: let 'qemu-img convert' flush data"). This expectation also encompasses that failure to do so is properly reported, so ensure that 'qemu-img convert' exits with a non-zero status code when the target image cannot be flushed. In particular, the reproducer below [0], based on a report by Ing. Alfonso Kuen Arroyo [1], would result in > rc=3D0 > Content mismatch at offset XYZ! before this change, and in > rc=3D1 > Content mismatch at offset XYZ! after this change. Note that this change does not affect the (default) 'unsafe' cache mode, because bdrv_co_flush() still skips flush to disk for that cache mode. [0]: > #!/bin/bash -x > dd if=3D/dev/urandom of=3Dsrc.raw bs=3D1M count=3D500 > truncate -s 500M dst.img > LOOP=3D$(losetup --find --show dst.img) > SIZE=3D$(blockdev --getsz $LOOP) > dd if=3D/dev/zero of=3D$LOOP bs=3D1M count=3D500 conv=3Dfsync status=3Dno= ne > sync > echo 3 > /proc/sys/vm/drop_caches > dmsetup create flk --table "0 $SIZE flakey $LOOP 0 5 5" > qemu-img convert -t writeback -p -r 100M -f raw -O raw src.raw /dev/mappe= r/flk > echo rc=3D$? > sleep 5 > dmsetup remove flk > qemu-img compare src.raw $LOOP > losetup -d $LOOP > rm src.raw dst.img [1]: https://lore.proxmox.com/pve-devel/178961792132.43804.1717323393529790= 3311@idkmanager.com/ Signed-off-by: Fiona Ebner Reviewed-by: Eric Blake --- qemu-img.c | 8 +++++++- tests/qemu-iotests/122.out | 3 ++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/qemu-img.c b/qemu-img.c index 2f63d31141..edf75e43ab 100644 --- a/qemu-img.c +++ b/qemu-img.c @@ -2245,7 +2245,7 @@ static int img_convert(const img_cmd_t *ccmd, int arg= c, char **argv) Error *local_err =3D NULL; bool writethrough, src_writethrough, image_opts =3D false, skip_create =3D false, progress =3D false, tgt_image_opts =3D fal= se; - int64_t ret =3D -EINVAL; + int64_t ret =3D -EINVAL, ret2; bool force_share =3D false; bool explict_min_sparse =3D false; bool bitmaps =3D false; @@ -2872,6 +2872,12 @@ static int img_convert(const img_cmd_t *ccmd, int ar= gc, char **argv) ret =3D convert_copy_bitmaps(blk_bs(s.src[0]), out_bs, skip_broken= ); } =20 + ret2 =3D blk_flush(s.target); + if (ret2 < 0) { + error_report("Failed to flush target image: %s", strerror(-ret2)); + ret =3D ret !=3D 0 ? ret : ret2; + } + out: if (!ret) { qemu_progress_print(100, 0); diff --git a/tests/qemu-iotests/122.out b/tests/qemu-iotests/122.out index 84283f2434..38794f96ac 100644 --- a/tests/qemu-iotests/122.out +++ b/tests/qemu-iotests/122.out @@ -267,9 +267,10 @@ qemu-img convert exited with status 0 =20 =3D=3D=3D failing flush after convert with 'writeback' cache mode =3D=3D= =3D =20 +qemu-img: Failed to flush target image: Input/output error qemu-img: Failed flush for 'json:{ /* filtered */ }' during close: Input/o= utput error qemu-img: Failed to flush the L2 table cache: Input/output error qemu-img: Failed to flush the refcount block cache: Input/output error qemu-img: Failed flush for 'json:{ /* filtered */ }' during close: Input/o= utput error -qemu-img convert exited with status 0 +qemu-img convert exited with status 1 *** done --=20 2.47.3