qemu-block
[Top][All Lists]
Advanced

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

Re: [PATCH] bugfix:migrate with block-dirty-bitmap (disk size is big eno


From: Vladimir Sementsov-Ogievskiy
Subject: Re: [PATCH] bugfix:migrate with block-dirty-bitmap (disk size is big enough) can't be finished
Date: Sat, 10 Sep 2022 13:58:12 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.1

Hi!

On 9/10/22 13:47, Seaway Liu(刘海伟) wrote:
hi,i have a question
if failed in migration using post-copy mode,is there some way to restore the 
memory data back to soucre VM?



As far as I understand, no, there is not.

Postcopy started actually means: target has started. So, RAM is touched by 
target VM process, no way to rollback.

Still, things are not so bad: when you enable dirty-bitmaps capability, but not 
postcopy-ram capability, RAM is migrated in precopy as usual. So, when target 
started, the only thing that is not yet migrated is dirty bitmap. So, in worst 
case (migration failure after postcopy started) you'll loose your dirty bitmap. 
VM is migrated and normally running on target. Unfinished bitmaps on target are 
automatically released (see cancel_incoming_locked()). So, in worst case you'll 
have to start your incremental backup chain from a new full-backup.



发自我的小米
在 Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>,2022年9月10日 下午6:18写道:

On 9/10/22 09:35, liuhaiwei wrote:
From: liuhaiwei <liuhaiwei@inspur.com>

bug description as  https://gitlab.com/qemu-project/qemu/-/issues/1203
Usually,we use the precopy or postcopy mode to migrate block dirty bitmap.
but if block-dirty-bitmap size more than threshold size,we cannot entry the 
migration_completion in migration_iteration_run function
To solve this problem, we can setting  the pending size to a fake 
value(threshold-1 or 0) to tell  migration_iteration_run function to entry the 
migration_completion,if pending size > threshold size



Actually, bitmaps migrate in postcopy. So, you should start postcopy for it to work (qmp 
command migrate-start-postcopy). This command simply set the boolean variable, so that in 
migration_iteration_run() we'll move to postcopy when needed. So, you can start this 
command immediately after migrate command, or even before it, but after setting the 
"dirty-bitmaps" capability.

Fake pending is a wrong thing to do, it means that you will make downtime to be 
larger than expected.

--
Best regards,
Vladimir


--
Best regards,
Vladimir



reply via email to

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