TRIAGE:
In is_active_bluestore_device call to check the return value of list_logical_volumes before attempting to get the zeroth value from the list.
diff --git a/lib/ceph/utils.py b/lib/ceph/utils.py index 35f351f..220039b 100644 --- a/lib/ceph/utils.py +++ b/lib/ceph/utils.py @@ -1692,7 +1692,11 @@ def is_active_bluestore_device(dev): return False
vg_name = lvm.list_lvm_volume_group(dev) - lv_name = lvm.list_logical_volumes('vg_name={}'.format(vg_name))[0] + logical_volumes = lvm.list_logical_volumes('vg_name={}'.format(vg_name)) + if logical_volumes: + lv_name = logical_volumes[0] + else: + return False
TRIAGE:
In is_active_ bluestore_ device call to check the return value of list_logical_ volumes before attempting to get the zeroth value from the list.
diff --git a/lib/ceph/utils.py b/lib/ceph/utils.py bluestore_ device( dev):
index 35f351f..220039b 100644
--- a/lib/ceph/utils.py
+++ b/lib/ceph/utils.py
@@ -1692,7 +1692,11 @@ def is_active_
return False
vg_name = lvm.list_ lvm_volume_ group(dev) logical_ volumes( 'vg_name= {}'.format( vg_name) )[0] logical_ volumes( 'vg_name= {}'.format( vg_name) )
- lv_name = lvm.list_
+ logical_volumes = lvm.list_
+ if logical_volumes:
+ lv_name = logical_volumes[0]
+ else:
+ return False