[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH 4/4] iotests: Add test 197 for covering copy-on-
From: |
Eric Blake |
Subject: |
Re: [Qemu-block] [PATCH 4/4] iotests: Add test 197 for covering copy-on-read |
Date: |
Mon, 2 Oct 2017 08:55:50 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 |
On 09/30/2017 10:03 PM, Jeff Cody wrote:
> On Sat, Sep 30, 2017 at 03:11:21PM -0500, Eric Blake wrote:
>> Add a test for qcow2 copy-on-read behavior, including exposure
>> for the just-fixed bugs.
>>
>> The copy-on-read behavior is always to a qcow2 image, but the
>> test is careful to allow running with most image protocol/format
>> combos as the backing file being copied from (luks being the
>> exception, as it is harder to pass the right secret to all the
>> right places). In fact, for './check nbd', this appears to be
>> the first time we've had a qcow2 image wrapping NBD, requiring
>> an additional line in _filter_img_create to match the similar
>> line in _filter_img_info.
>>
>> Signed-off-by: Eric Blake <address@hidden>
>>
>> +_cleanup()
>> +{
>> + _cleanup_test_img
>> + rm -f "$BLKDBG_CONF"
>> +}
>> +trap "_cleanup; exit \$status" 0 1 2 3 15
>
>
> Note to myself to add this to my iotests series.
Yep, and I even thought about that, since I've been pointing it out on
other patches, but forgot to mention it when composing the email ;)
>> +$QEMU_IO -c "open -C \
>> + -o driver=blkdebug,config=$BLKDBG_CONF,image.driver=qcow2 $TEST_WRAP" \
>
> Hmm, this will lead to issues if $TEST_WRAP has spaces, right?
Probably :( Although I didn't actually test that setup
But I don't know what other options we have to work around it. As long
as we are executing in the correct directory, I guess we can open both
BLKDBG_CONF and TEST_WRAP relative to ./ rather than as an absolute
path, and that should be sufficient to avoid spaces. But I don't know
how easy that is to achieve, or if _filter_qemu_io will handle it correctly.
Maybe I take the wimpy way out and skip the test if $PWD contains spaces
or other problematic characters?
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-block] [PATCH 4/4] iotests: Add test 197 for covering copy-on-read,
Eric Blake <=