]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
Added copy-on-write support for all RBD cloning
authorEdward Hope-Morley <edward.hope-morley@canonical.com>
Mon, 12 Aug 2013 16:46:38 +0000 (17:46 +0100)
committerEdward Hope-Morley <edward.hope-morley@canonical.com>
Thu, 5 Sep 2013 13:25:59 +0000 (14:25 +0100)
commit52291d6554f2275b228d7039d222bccfab164106
treead27a0b8af2e9a103da141a3ecb813b1f9109c50
parent59941331f8505e97bef676c6e9a3725e911b1014
Added copy-on-write support for all RBD cloning

Up till now we only had copy-on-write for cloning from snapshot. This
change optionally allows clone from volume to use copy-on-write
instead of a doing a full copy each time. This should increase speed
and reduce nearterm storage consumtion but could introduce some new
risks e.g. excessively long clone chains and flatten storms. To avoid
this, a new config option has been providedons are provided -
rbd_max_clone_depth - which allows the user to limit the depth of a
chain of clones i.e.

    a->b->c->d as opposed to a->b
                              ->c
                              ->d

This will avoid flatten storms by breaking chains as they are formed
and at an early, predefined stage.

A second option - rbd_clone_from_volume_force_copy - allows the user
to use a full copy as before i.e. disable COW for volume clones.

Implements: blueprint use-copy-on-write-for-all-volume-cloning
Fixes: bug #1209199
Change-Id: Ia4a8a10c797cda2cf1ef3a2e9bd49f8c084ec977
cinder/tests/backup/fake_rados.py
cinder/tests/test_rbd.py
cinder/volume/drivers/rbd.py
etc/cinder/cinder.conf.sample