[pve-devel] [PATCH qemu-server] migrate: keep VM paused after migration if it was before
Fabian Grünbichler
f.gruenbichler at proxmox.com
Thu Apr 21 09:35:25 CEST 2022
On April 21, 2022 9:20 am, Fabian Ebner wrote:
> Am 20.04.22 um 14:43 schrieb Fabian Grünbichler:
>> one other thing I noticed (pre-existing, but the changes here made me
>> look and my search came up short), inside phase2:
>>
>> - start block job(s) without autocompletion and wait for them to
>> converge
>> - start RAM/state migration without autocompletion and wait for it to
>> converge
>> X both source and target VMs are paused now with "identical" state,
>> irrespective of the source being paused or not initially
>> - cancel block job(s) (to close NBD writer(s) so that switchover can
>> proceed in phase3_cleanup)
>>
>> if something happens after X in phase2, we enter phase2_cleanup, and
>> attempt to cancel the migration, remove the lock, cancel the block jobs
>> again, clean up bitmaps, stop the target VM, clean up remote disks, tear
>> down the tunnel, and effectively exit the migration at that point BUT -
>> we don't handle the paused state? is there a resume source (with this
>> patch, guarded by source was not paused) missing or am I missing
>> something?
>
> Quickly tested it, but there is no resume call for the source (with or
> without the patch) in this scenario. I don't think there is any real
> downside to try and resume on the source in phase2_cleanup().
exactly - I expected such a call to be there somewhere in error handling
(similar to the vzdump flow), but didn't find it. it was just your patch
that made me look, not that your patch made anything worse ;)
More information about the pve-devel
mailing list