[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH v6 14/15] block: Rewrite bdrv_close_all()

From: Eric Blake
Subject: Re: [Qemu-block] [PATCH v6 14/15] block: Rewrite bdrv_close_all()
Date: Thu, 5 Nov 2015 10:44:38 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

On 11/05/2015 10:40 AM, Paolo Bonzini wrote:
> On 05/11/2015 18:37, Max Reitz wrote:
>> $ x86_64-softmmu/qemu-system-x86_64 -qmp stdio \ -drive
>> if=none,file=test.qcow2,id=drive0,node-name=node0 {"QMP":
>> {"version": {"qemu": {"micro": 50, "minor": 4, "major": 2}, 
>> "package": ""}, "capabilities": []}} 
>> {'execute':'qmp_capabilities'} {"return": {}} 
>> {'execute':'drive-backup','arguments':{'device':'drive0','target':'out.qcow2','format':'qcow2','sync':'none'}}
> Formatting 'out.qcow2', fmt=qcow2 size=67108864 backing_file=test.qcow2
>> backing_fmt=qcow2 encryption=off cluster_size=65536
>> lazy_refcounts=off refcount_bits=16 {"return": {}} 
>> {'execute':'eject','arguments':{'device':'drive0'}} {"error":
>> {"class": "GenericError", "desc": "Node 'drive0' is busy: block
>> device is in use by block job: backup"}}
>> So... Nobody does it, but apparently nobody has to because you
>> cannot eject (to be more specific: use blockdev-remove-medium) a
>> BDS from a BB while a block job is running on the BDS.
> If you test it with all jobs, then it's okay.  It's a regression, but
> not introduced by your patch and apparently nobody noticed.
> Even if nobody noticed, I wonder if this "Node 'foo' is busy" kind of
> error deserves its own ErrorClass.  Eric, what do you think?

Needing a unique ErrorClass is only important if we expect a client
(libvirt) would behave differently based on that error class (clients
are not allowed to parse the error message).  But what is the scenario
that we are trying to test here, rewritten in terms of libvirt API
commands?  Should libvirt behave any differently because a blockjob was
running than for any other failure, if the end result is still that
libvirt can't eject or hot-unplug the disk because of a failure?

Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]