Skip to content

Commit 1bc0a94

Browse files
committed
ignore drives in state 'Absent' on Cisco servers #131
1 parent 36ccd60 commit 1bc0a94

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

cr_module/storage.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -596,6 +596,12 @@ def get_drive(drive_link):
596596
# get status data
597597
status_data = get_status_data(drive_response.get("Status"))
598598

599+
# ignore "Absent" drives on Cisco servers
600+
if (plugin_object.rf.vendor == "Cisco" and
601+
status_data.get("Health") == "OK" and
602+
status_data.get("State") == "Absent"):
603+
return
604+
599605
# get disk size
600606
disk_size = None
601607
if drive_response.get("CapacityLogicalBlocks") is not None and \

0 commit comments

Comments
 (0)