[pve-devel] [PATCH qemu-server 1/2] Fix #1441: Do not unplug controllers when the mirroring is finished

Emmanuel Kasper e.kasper at proxmox.com
Thu Aug 24 09:57:37 CEST 2017



On 08/24/2017 08:30 AM, Fabian Gr├╝nbichler wrote:
> On Thu, Aug 24, 2017 at 07:05:35AM +0200, Thomas Lamprecht wrote:
>> On 08/23/2017 07:15 PM, Alexandre DERUMIER wrote:
>>> for me, this patch is ok.
>>>
>>> if the job is complete, we don't need to unplug. (and that mean that vm need to support unplug too, we can't be sure that guest support this).
>>>
>>> Is it possible that the problem was the previous bug with unix socket, were the target vm was not paused after migration ?
>>>
>>
>> Could be possible.
>>
>> Looking at the qemu-server and qemu source Emmanuel's patch seems, in fact, valid.
>>
>> All mirror block jobs are finished at this point, we do a "nbd-server-stop" on,
>> the target which disconnects all NBD clients, as everything from the source side
>> using NBD is mirrored, flushed and happy this should not run into a problem there.
>>
>> Same for qemu's do_vm_stop, which drains and flushes all remaining blockjobs (which
>> there shouldn't be any a this point, else we would have mirrored/migrated an unclean
>> state?!)
>>
>> I'd still wait for Wolfgang B.'s opinion on this, he knows far more on the topic.
> 
> I originally added the device_del because I experienced long delays in
> stopping the source VM, but I did not debug further (and unfortunately
> cannot remember more details). if such delays are not reproducible
> (anymore) when taking out that foreach, I am OK with it.
> 

I could not reproduce the problem of a migration taking a longer time
without the hotplug.

After the mirroring is complete, phase3_cleanup takes between 4s and 10s
in my tests, with or without unplug.
see https://bugzilla.proxmox.com/show_bug.cgi?id=1441 for some test outputs





More information about the pve-devel mailing list