[openstack-dev] [nova][libvirt] VIR_MIGRATE_NON_SHARED_INC works more like full copy in block migration ?
kchamart at redhat.com
Tue Jan 12 11:35:48 UTC 2016
On Sun, Jan 10, 2016 at 06:07:33PM +0800, Luo Gangyi wrote:
> Hi devs,
> Do you test the difference between within and without
> VIR_MIGRATE_NON_SHARED_INC ?
> When I add VIR_MIGRATE_NON_SHARED_INC in block_migration_flags in
> nova, nova block migration behaves more like a full copy of disk. The
> disk in destination nodes is large(10GB+) and the process of live
> migration is slow.
> However, when I remove VIR_MIGRATE_NON_SHARED_INC in
> block_migration_flags in nova, nova block migration behaves more like
> a incremental copy of disk. The disk in destination nodes is
> small(10MB-) and the process of live migration is very fast.
> So I was confused about what VIR_MIGRATE_NON_SHARED_INC really means.
There are two flags that are related, that might be helpful to be clear
about: VIR_MIGRATE_NON_SHARED_DISK and VIR_MIGRATE_NON_SHARED_INC.
Below is an explanation with example, by Eric Blake, from
NB: It is talking in terms of `virsh` commands, where
'--copy-storage-all' means VIR_MIGRATE_NON_SHARED_DISK and
'--copy-storage-inc' means VIR_MIGRATE_NON_SHARED_INC:
"If you use qcow2 backing chains for thin provisioning, as in:
base.qcow2 <- active.qcow2
then --copy-storage-all copies the entire disk over to the
destination (both base.qcow2 and active.qcow2 contents), while
--copy-storage-inc copies only active.qcow2 (and assumes you have
manually copied base.qcow2 in some other means - since it is
read-only, it won't change from the last migration, and there are
some storage arrays where you can very efficiently copy files
around). Thus, --copy-storage-inc can be MUCH faster if
active.qcow2 represents a small delta in relation to base.qcow2."
Semantics of "virsh migrate --copy-storage-all" vs.
More information about the OpenStack-dev