* [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running
@ 2017-12-25 2:51 Fam Zheng
2018-01-03 22:18 ` Eric Blake
2018-03-05 15:51 ` Max Reitz
0 siblings, 2 replies; 5+ messages in thread
From: Fam Zheng @ 2017-12-25 2:51 UTC (permalink / raw)
To: qemu-devel; +Cc: eblake, Kevin Wolf, Max Reitz, qemu-block
Signed-off-by: Fam Zheng <famz@redhat.com>
---
v2: Actually test the thing. [Kevin]
---
tests/qemu-iotests/153 | 8 +++++---
tests/qemu-iotests/153.out | 7 ++++---
2 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/153 b/tests/qemu-iotests/153
index fa25eb24bd..adfd02695b 100755
--- a/tests/qemu-iotests/153
+++ b/tests/qemu-iotests/153
@@ -32,6 +32,7 @@ _cleanup()
{
_cleanup_test_img
rm -f "${TEST_IMG}.base"
+ rm -f "${TEST_IMG}.overlay"
rm -f "${TEST_IMG}.convert"
rm -f "${TEST_IMG}.a"
rm -f "${TEST_IMG}.b"
@@ -177,8 +178,6 @@ rm -f "${TEST_IMG}.lnk" &>/dev/null
ln -s ${TEST_IMG} "${TEST_IMG}.lnk" || echo "Failed to create link"
_run_qemu_with_images "${TEST_IMG}.lnk" "${TEST_IMG}"
-echo
-echo "== Closing an image should unlock it =="
_launch_qemu
_send_qemu_cmd $QEMU_HANDLE \
@@ -193,7 +192,10 @@ _send_qemu_cmd $QEMU_HANDLE \
_run_cmd $QEMU_IO "${TEST_IMG}" -c 'write 0 512'
-echo "Closing drive"
+echo "Creating overlay with qemu-img when the guest is running should be allowed"
+_run_cmd $QEMU_IMG create -f $IMGFMT -b "${TEST_IMG}" "${TEST_IMG}.overlay"
+
+echo "== Closing an image should unlock it =="
_send_qemu_cmd $QEMU_HANDLE \
"{ 'execute': 'human-monitor-command',
'arguments': { 'command-line': 'drive_del d0' } }" \
diff --git a/tests/qemu-iotests/153.out b/tests/qemu-iotests/153.out
index 5b917b177c..34309cfb20 100644
--- a/tests/qemu-iotests/153.out
+++ b/tests/qemu-iotests/153.out
@@ -372,15 +372,16 @@ Is another process using the image?
== Symbolic link ==
QEMU_PROG: -drive if=none,file=TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image?
-
-== Closing an image should unlock it ==
{"return": {}}
Adding drive
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image?
-Closing drive
+Creating overlay with qemu-img when the guest is running should be allowed
+
+_qemu_img_wrapper create -f qcow2 -b TEST_DIR/t.qcow2 TEST_DIR/t.qcow2.overlay
+== Closing an image should unlock it ==
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
Adding two and closing one
--
2.14.3
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running
2017-12-25 2:51 [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running Fam Zheng
@ 2018-01-03 22:18 ` Eric Blake
2018-02-14 1:26 ` Fam Zheng
2018-03-05 15:51 ` Max Reitz
1 sibling, 1 reply; 5+ messages in thread
From: Eric Blake @ 2018-01-03 22:18 UTC (permalink / raw)
To: Fam Zheng, qemu-devel; +Cc: Kevin Wolf, Max Reitz, qemu-block, Jeff Cody
[-- Attachment #1: Type: text/plain, Size: 862 bytes --]
On 12/24/2017 08:51 PM, Fam Zheng wrote:
> Signed-off-by: Fam Zheng <famz@redhat.com>
>
> ---
>
> v2: Actually test the thing. [Kevin]
> ---
> tests/qemu-iotests/153 | 8 +++++---
> tests/qemu-iotests/153.out | 7 ++++---
> 2 files changed, 9 insertions(+), 6 deletions(-)
Reviewed-by: Eric Blake <eblake@redhat.com>
>
> diff --git a/tests/qemu-iotests/153 b/tests/qemu-iotests/153
> index fa25eb24bd..adfd02695b 100755
> --- a/tests/qemu-iotests/153
> +++ b/tests/qemu-iotests/153
> @@ -32,6 +32,7 @@ _cleanup()
> {
> _cleanup_test_img
> rm -f "${TEST_IMG}.base"
> + rm -f "${TEST_IMG}.overlay"
Trivial conflict with Jeff's work to do per-test temporary directories
in iotests.
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 619 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running
2018-01-03 22:18 ` Eric Blake
@ 2018-02-14 1:26 ` Fam Zheng
2018-03-01 7:19 ` Fam Zheng
0 siblings, 1 reply; 5+ messages in thread
From: Fam Zheng @ 2018-02-14 1:26 UTC (permalink / raw)
To: Eric Blake; +Cc: QEMU Developers, Kevin Wolf, Max Reitz, qemu-block, Jeff Cody
Ping?
On Thu, Jan 4, 2018 at 6:18 AM, Eric Blake <eblake@redhat.com> wrote:
> On 12/24/2017 08:51 PM, Fam Zheng wrote:
>> Signed-off-by: Fam Zheng <famz@redhat.com>
>>
>> ---
>>
>> v2: Actually test the thing. [Kevin]
>> ---
>> tests/qemu-iotests/153 | 8 +++++---
>> tests/qemu-iotests/153.out | 7 ++++---
>> 2 files changed, 9 insertions(+), 6 deletions(-)
>
> Reviewed-by: Eric Blake <eblake@redhat.com>
>
>>
>> diff --git a/tests/qemu-iotests/153 b/tests/qemu-iotests/153
>> index fa25eb24bd..adfd02695b 100755
>> --- a/tests/qemu-iotests/153
>> +++ b/tests/qemu-iotests/153
>> @@ -32,6 +32,7 @@ _cleanup()
>> {
>> _cleanup_test_img
>> rm -f "${TEST_IMG}.base"
>> + rm -f "${TEST_IMG}.overlay"
>
> Trivial conflict with Jeff's work to do per-test temporary directories
> in iotests.
>
> --
> Eric Blake, Principal Software Engineer
> Red Hat, Inc. +1-919-301-3266
> Virtualization: qemu.org | libvirt.org
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running
2018-02-14 1:26 ` Fam Zheng
@ 2018-03-01 7:19 ` Fam Zheng
0 siblings, 0 replies; 5+ messages in thread
From: Fam Zheng @ 2018-03-01 7:19 UTC (permalink / raw)
To: Eric Blake; +Cc: QEMU Developers, Kevin Wolf, Max Reitz, qemu-block, Jeff Cody
On Wed, 02/14 09:26, Fam Zheng wrote:
> Ping?
Ping?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running
2017-12-25 2:51 [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running Fam Zheng
2018-01-03 22:18 ` Eric Blake
@ 2018-03-05 15:51 ` Max Reitz
1 sibling, 0 replies; 5+ messages in thread
From: Max Reitz @ 2018-03-05 15:51 UTC (permalink / raw)
To: Fam Zheng, qemu-devel; +Cc: eblake, Kevin Wolf, qemu-block
[-- Attachment #1: Type: text/plain, Size: 382 bytes --]
On 2017-12-25 03:51, Fam Zheng wrote:
> Signed-off-by: Fam Zheng <famz@redhat.com>
>
> ---
>
> v2: Actually test the thing. [Kevin]
> ---
> tests/qemu-iotests/153 | 8 +++++---
> tests/qemu-iotests/153.out | 7 ++++---
> 2 files changed, 9 insertions(+), 6 deletions(-)
Thanks, applied to my block tree:
https://github.com/XanClic/qemu/commits/block
Max
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 512 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-03-05 15:52 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-25 2:51 [Qemu-devel] [PATCH v2] iotests: Test creating overlay when guest running Fam Zheng
2018-01-03 22:18 ` Eric Blake
2018-02-14 1:26 ` Fam Zheng
2018-03-01 7:19 ` Fam Zheng
2018-03-05 15:51 ` Max Reitz
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).