VMDK driver does not allow snapshot deletion if the volume
is attached. Currently we assume the volume to be attached
if it's state is not 'available', which is wrong. During
cascade delete, the volume status is set to 'deleting'.
Therefore, snapshot deletion fails even if the volume is
not attached. Fixing this by using volume attachment info
to check for attached volumes.
Reviewed: https:/ /review. openstack. org/479095 /git.openstack. org/cgit/ openstack/ cinder/ commit/ ?id=c4cc7df0bd8 9d4d8348a05d8e4 2a7b24afdca844
Committed: https:/
Submitter: Jenkins
Branch: master
commit c4cc7df0bd89d4d 8348a05d8e42a7b 24afdca844
Author: Vipin Balachandran <email address hidden>
Date: Thu Jun 29 16:35:27 2017 -0700
VMware: Fix volume cascade delete
VMDK driver does not allow snapshot deletion if the volume
is attached. Currently we assume the volume to be attached
if it's state is not 'available', which is wrong. During
cascade delete, the volume status is set to 'deleting'.
Therefore, snapshot deletion fails even if the volume is
not attached. Fixing this by using volume attachment info
to check for attached volumes.
Change-Id: I83874d6d287fe3 950b003f7eac74d b9a1602432e
Closes-bug: #1701393