From: Max Reitz <mreitz@redhat.com>
To: qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>,
Stefan Hajnoczi <stefanha@redhat.com>,
Max Reitz <mreitz@redhat.com>
Subject: [Qemu-devel] [PATCH 8/8] iotests: Expand test 061
Date: Fri, 25 Jul 2014 20:07:45 +0200 [thread overview]
Message-ID: <1406311665-2814-9-git-send-email-mreitz@redhat.com> (raw)
In-Reply-To: <1406311665-2814-1-git-send-email-mreitz@redhat.com>
Add some tests for progress output and one test regarding the COPIED
flag for shared zeroed clusters to 061.
Signed-off-by: Max Reitz <mreitz@redhat.com>
---
tests/qemu-iotests/061 | 41 +++++++++++++++++++++++++++++++++++++++++
tests/qemu-iotests/061.out | 40 ++++++++++++++++++++++++++++++++++++++++
tests/qemu-iotests/group | 2 +-
3 files changed, 82 insertions(+), 1 deletion(-)
diff --git a/tests/qemu-iotests/061 b/tests/qemu-iotests/061
index ab98def..12ea687 100755
--- a/tests/qemu-iotests/061
+++ b/tests/qemu-iotests/061
@@ -209,6 +209,47 @@ $QEMU_IMG amend -o "compat=0.10" "$TEST_IMG"
_check_test_img
$QEMU_IO -c "read -P 0 0 64M" "$TEST_IMG" | _filter_qemu_io
+echo
+echo "=== Testing multiple zeroed cluster allocations ==="
+echo
+IMGOPTS="compat=1.1" TEST_IMG="$TEST_IMG.base" _make_test_img 64M
+IMGOPTS="compat=1.1,cluster_size=512" make_test_img -b "$TEST_IMG.base" 64M
+$QEMU_IO -c "write -z 0 $(((2 * 65535 + 1) * 512))" "$TEST_IMG" \
+ | _filter_qemu_io
+$QEMU_IMG amend -o "compat=0.10" "$TEST_IMG"
+_check_test_img
+
+echo
+echo "=== Testing progress report without snapshot ==="
+echo
+IMGOPTS="compat=1.1" TEST_IMG="$TEST_IMG.base" _make_test_img 4G
+IMGOPTS="compat=1.1" _make_test_img -b "$TEST_IMG.base" 4G
+$QEMU_IO -c "write -z 0 64k" \
+ -c "write -z 1G 64k" \
+ -c "write -z 2G 64k" \
+ -c "write -z 3G 64k" "$TEST_IMG" | _filter_qemu_io
+$QEMU_IMG amend -p -o "compat=0.10" "$TEST_IMG"
+_check_test_img
+
+echo
+echo "=== Testing progress report with snapshot ==="
+echo
+IMGOPTS="compat=1.1" TEST_IMG="$TEST_IMG.base" _make_test_img 4G
+IMGOPTS="compat=1.1" _make_test_img -b "$TEST_IMG.base" 4G
+$QEMU_IO -c "write -z 0 64k" \
+ -c "write -z 1G 64k" \
+ -c "write -z 2G 64k" \
+ -c "write -z 3G 64k" "$TEST_IMG" | _filter_qemu_io
+$QEMU_IMG snapshot -c foo "$TEST_IMG"
+# COW L2 table 0
+$QEMU_IO -c "write -z 64k 64k" "$TEST_IMG" | _filter_qemu_io
+# The first four steps will advance by 2/9, because in the active L1 table, the
+# first L2 table contains two zero cluster entries and all others contain one
+# but are shared with the other L2 table; the final 1/9 step will be from the
+# zero cluster entry in the L2 table owned exclusively by the snapshot.
+$QEMU_IMG amend -p -o "compat=0.10" "$TEST_IMG"
+_check_test_img
+
# success, all done
echo "*** done"
rm -f $seq.full
diff --git a/tests/qemu-iotests/061.out b/tests/qemu-iotests/061.out
index e372470..63d7bb2 100644
--- a/tests/qemu-iotests/061.out
+++ b/tests/qemu-iotests/061.out
@@ -384,4 +384,44 @@ wrote 67108864/67108864 bytes at offset 0
No errors were found on the image.
read 67108864/67108864 bytes at offset 0
64 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+
+=== Testing multiple zeroed cluster allocations ===
+
+Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=67108864
+./061: line 216: make_test_img: command not found
+wrote 67108352/67108352 bytes at offset 0
+64 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+No errors were found on the image.
+
+=== Testing progress report without snapshot ===
+
+Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=4294967296
+Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4294967296 backing_file='TEST_DIR/t.IMGFMT.base'
+wrote 65536/65536 bytes at offset 0
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 1073741824
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 2147483648
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 3221225472
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+ (0.00/100%)
(25.00/100%)
(50.00/100%)
(75.00/100%)
(100.00/100%)
(100.00/100%)
+No errors were found on the image.
+
+=== Testing progress report with snapshot ===
+
+Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=4294967296
+Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4294967296 backing_file='TEST_DIR/t.IMGFMT.base'
+wrote 65536/65536 bytes at offset 0
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 1073741824
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 2147483648
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 3221225472
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+wrote 65536/65536 bytes at offset 65536
+64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+ (0.00/100%)
(22.22/100%)
(44.44/100%)
(66.67/100%)
(88.89/100%)
(100.00/100%)
(100.00/100%)
(100.00/100%)
(100.00/100%)
(100.00/100%)
+No errors were found on the image.
*** done
diff --git a/tests/qemu-iotests/group b/tests/qemu-iotests/group
index 6e67f61..b27e2f9 100644
--- a/tests/qemu-iotests/group
+++ b/tests/qemu-iotests/group
@@ -67,7 +67,7 @@
058 rw auto quick
059 rw auto quick
060 rw auto quick
-061 rw auto quick
+061 rw auto
062 rw auto quick
063 rw auto quick
064 rw auto quick
--
2.0.1
prev parent reply other threads:[~2014-07-25 18:07 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-25 18:07 [Qemu-devel] [PATCH 0/8] block/qcow2: Improve (?) zero cluster expansion Max Reitz
2014-07-25 18:07 ` [Qemu-devel] [PATCH 1/8] block: Add status callback to bdrv_amend_options() Max Reitz
2014-07-30 14:50 ` Eric Blake
2014-07-25 18:07 ` [Qemu-devel] [PATCH 2/8] qemu-img: Add progress output for amend Max Reitz
2014-07-30 14:55 ` Eric Blake
2014-07-30 20:20 ` Max Reitz
2014-07-25 18:07 ` [Qemu-devel] [PATCH 3/8] qemu-img: Fix insignifcant memleak Max Reitz
2014-07-30 14:56 ` Eric Blake
2014-07-25 18:07 ` [Qemu-devel] [PATCH 4/8] block/qcow2: Make get_refcount() global Max Reitz
2014-07-30 15:04 ` Eric Blake
2014-07-25 18:07 ` [Qemu-devel] [PATCH 5/8] block/qcow2: Implement status CB for amend Max Reitz
2014-07-30 15:23 ` Eric Blake
2014-07-25 18:07 ` [Qemu-devel] [PATCH 6/8] block/qcow2: Simplify shared L2 handling in amend Max Reitz
2014-07-30 15:36 ` Eric Blake
2014-07-25 18:07 ` [Qemu-devel] [PATCH 7/8] block/qcow2: Speed up zero cluster expansion Max Reitz
2014-07-30 16:14 ` Eric Blake
2014-07-30 20:31 ` Max Reitz
2014-07-30 20:31 ` Eric Blake
2014-07-30 20:41 ` Max Reitz
2014-07-25 18:07 ` Max Reitz [this message]
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=1406311665-2814-9-git-send-email-mreitz@redhat.com \
--to=mreitz@redhat.com \
--cc=kwolf@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.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).