]> git.proxmox.com Git - qemu.git/commit - migration.c
add non-arbitrary migration stop condition
authorGlauber Costa <glommer@redhat.com>
Thu, 28 May 2009 19:22:57 +0000 (15:22 -0400)
committerAnthony Liguori <aliguori@us.ibm.com>
Tue, 16 Jun 2009 20:45:40 +0000 (15:45 -0500)
commita0a3fd60f66bfdef38da835e7382b0bfbe05bafc
tree828a90711bce2e7e9e3a26ff6f899a316052158b
parent8c14c17395809dfb2b20bd3598e067d2c5af7dc4
add non-arbitrary migration stop condition

Currently, we're entering migration's stage 3 when
a treshold of 10 pages remain to be transferred in the system.

This has hurt some users. However, any proposed threshold is
arbitrary by nature, and would only shift the annoyance.

The proposal of this patch is to define a max_downtime variable,
which represents the maximum downtime a migration user is willing
to suffer. Then, based on the bandwidth of last iteration, we
calculate how much data we can transfer in such a window of time.

Whenever we reach that value (or lower), we know is safe to enter
stage3.

This has largely improved the situation for me.
On localhost migrations, where one would expect things to go as
quickly as me running away from the duty of writting software for
windows, a kernel compile was enough to get the migration stuck.

It takes 20 ~ 30 iterations now.

Signed-off-by: Glauber Costa <glommer@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
migration.c
migration.h
vl.c