Skip to content

Instantly share code, notes, and snippets.

@WaltHP
Created May 17, 2016 22:16
Show Gist options
  • Select an option

  • Save WaltHP/dd4aea55209fc48f1fc82cd97904f904 to your computer and use it in GitHub Desktop.

Select an option

Save WaltHP/dd4aea55209fc48f1fc82cd97904f904 to your computer and use it in GitHub Desktop.
diff --git a/cinder/volume/drivers/san/hp/hp_3par_common.py b/cinder/volume/drivers/san/hp/hp_3par_common.py
index 3081c33..db4a063 100644
--- a/cinder/volume/drivers/san/hp/hp_3par_common.py
+++ b/cinder/volume/drivers/san/hp/hp_3par_common.py
@@ -1066,11 +1066,18 @@ class HP3PARCommon(object):
active_volume_vluns.append(vlun)
else:
inactive_volume_vluns.append(vlun)
+
if active_volume_vluns:
volume_vluns = active_volume_vluns
elif inactive_volume_vluns:
volume_vluns = inactive_volume_vluns
+ # FIXME(walter-boring) temporary fix to ensure all VLUNs are removed
+ # 'inactive' is actuall a misnomer. The 3PAR 'inactive' means a
+ # template VLUN. If you delete the template, all Active VLUNs are
+ # removed.
+ volume_vluns = inactive_volume_vluns
+
if not volume_vluns:
msg = (
_LW("3PAR vlun for volume %(name)s not found on "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment