]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
VMware: Disallow snapshot of attached volume
authorKartik Bommepally <kbommepally@vmware.com>
Tue, 8 Oct 2013 13:33:33 +0000 (06:33 -0700)
committerKartik Bommepally <kbommepally@vmware.com>
Wed, 9 Oct 2013 05:33:18 +0000 (22:33 -0700)
commit2451a027bee50c834890f9e049fbaf4bfa911546
tree8581b33f927edfa342339d7ee311f1f1c59e90b3
parentb00e307d7067e4b9cc86739291668be5b518badf
VMware: Disallow snapshot of attached volume

The current implementation perform snapshot of attached volume.
This is invalid because when we take snapshot of the backing, the instance
continues pointing to the readonly delta and tries writing to it.
This patch will disallow snapshot creation of attached volume.

We have similar issue with delete of snapshot, when deleted the instance will
point to an invalid disk file, since that will get merged with its parent.
Hence any writes by the instance will fail with disk not found error.
This patch will ignore delete snapshot of attached volume.

Since we disallow snapshot of attached volume, we disallow linked clone of
attached source volume and also upload of attached volume.

Fixes bug: 1236891

Change-Id: I6a91eac8529836d1fe1de73bf6b28ec098aa7c54
cinder/tests/test_vmware_vmdk.py
cinder/volume/drivers/vmware/vmdk.py