diff options
author | Mike Christie <mchristi@redhat.com> | 2017-01-03 13:22:32 -0600 |
---|---|---|
committer | Mike Christie <mchristi@redhat.com> | 2017-01-03 13:56:28 -0600 |
commit | 163ee011246971ea3f6a00acd98df5a2df9a8166 (patch) | |
tree | 995a043317e5a9491a78e66f106b73847a7fb0dc | |
parent | b85519f44bd7e940243d89fccf8b59992ef8361a (diff) | |
download | rtslib-fb-163ee011246971ea3f6a00acd98df5a2df9a8166.tar.gz |
Delete ALUA groups with its storage object
We must delete the ALUA groups under the storage object
when deleting the storage object.
Signed-off-by: Mike Christie <mchristi@redhat.com>
-rw-r--r-- | rtslib/tcm.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/rtslib/tcm.py b/rtslib/tcm.py index 64dd48c..5452f92 100644 --- a/rtslib/tcm.py +++ b/rtslib/tcm.py @@ -235,6 +235,10 @@ class StorageObject(CFSNode): ''' self._check_self() + for alua_tpg in self._list_alua_tpgs(): + if alua_tpg.name != 'default_tg_pt_gp': + alua_tpg.delete() + # If we are called after a configure error, we can skip this if self.is_configured(): for lun in self._gen_attached_luns(): |