diff --git a/areca/agent_based/areca_hba_fans b/areca/agent_based/areca_hba_fans.py similarity index 100% rename from areca/agent_based/areca_hba_fans rename to areca/agent_based/areca_hba_fans.py diff --git a/areca/agent_based/areca_hba_ldisks b/areca/agent_based/areca_hba_ldisks.py similarity index 97% rename from areca/agent_based/areca_hba_ldisks rename to areca/agent_based/areca_hba_ldisks.py index bb5ec8c3..a74f0718 100644 --- a/areca/agent_based/areca_hba_ldisks +++ b/areca/agent_based/areca_hba_ldisks.py @@ -58,7 +58,7 @@ def discover_areca_hba_ldisks(section) -> DiscoveryResult: for id in section.keys(): yield Service(item=id) -def check_areca_hba_ldisks(item, _no_params, section) -> CheckResult: +def check_areca_hba_ldisks(item, section) -> CheckResult: if item in section: vsf = section[item] state = State.UNKNOWN @@ -79,6 +79,7 @@ def check_areca_hba_ldisks(item, _no_params, section) -> CheckResult: name = "areca_hba_ldisks", parse_function = parse_areca_hba_ldisks, detect = startswith(".1.3.6.1.2.1.1.2.0", ".1.3.6.1.4.1.18928.1"), + # detect = lambda oid: True, fetch = SNMPTree( base = ".1.3.6.1.4.1.18928.1.2.5.1.1", oids = [ diff --git a/areca/agent_based/areca_hba_pdisks b/areca/agent_based/areca_hba_pdisks.py similarity index 73% rename from areca/agent_based/areca_hba_pdisks rename to areca/agent_based/areca_hba_pdisks.py index 1ded078d..255ead19 100644 --- a/areca/agent_based/areca_hba_pdisks +++ b/areca/agent_based/areca_hba_pdisks.py @@ -88,30 +88,30 @@ def check_areca_hba_pdisks(item, _no_params, info): return (3, "Disk not found in agent output") -check_info["areca_hba_pdisks"] = { - "check_function" : check_areca_hba_pdisks, - "inventory_function" : inventory_areca_hba_pdisks, - "has_perfdata" : False, - "service_description" : "PDisk Enc/Sl %s", - # Find Areca SAS MIB - "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), - "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.3", - # unclear: how does it look in jbod mode? - # where does i get pony? - # There's up to 8 enclosures, "1" is hardcoded having 8 slots. - # probably it's the ext. SAS connector. - [ "1", "2", "3", "4", "5", "6", "7", "8" ], - # Below each enclosure there's the following structure for disk data - [ "4.1.1", # The slot ids - "4.1.2", # The slot descrs - "4.1.3", # The disk model - "4.1.4", # The disk fw - "4.1.5", # The disk size - # The MIB seems wrong about the next ones - "4.1.6", # - "4.1.7", # - "4.1.8", # Textual disk state - ] - )], -} +# check_info["areca_hba_pdisks"] = { +# "check_function" : check_areca_hba_pdisks, +# "inventory_function" : inventory_areca_hba_pdisks, +# "has_perfdata" : False, +# "service_description" : "PDisk Enc/Sl %s", +# # Find Areca SAS MIB +# "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), +# "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.3", +# # unclear: how does it look in jbod mode? +# # where does i get pony? +# # There's up to 8 enclosures, "1" is hardcoded having 8 slots. +# # probably it's the ext. SAS connector. +# [ "1", "2", "3", "4", "5", "6", "7", "8" ], +# # Below each enclosure there's the following structure for disk data +# [ "4.1.1", # The slot ids +# "4.1.2", # The slot descrs +# "4.1.3", # The disk model +# "4.1.4", # The disk fw +# "4.1.5", # The disk size +# # The MIB seems wrong about the next ones +# "4.1.6", # +# "4.1.7", # +# "4.1.8", # Textual disk state +# ] +# )], +# } diff --git a/areca/agent_based/areca_hba_raidsets b/areca/agent_based/areca_hba_raidsets.py similarity index 74% rename from areca/agent_based/areca_hba_raidsets rename to areca/agent_based/areca_hba_raidsets.py index de329cfd..58c469e0 100644 --- a/areca/agent_based/areca_hba_raidsets +++ b/areca/agent_based/areca_hba_raidsets.py @@ -57,22 +57,22 @@ def check_areca_hba_raidsets(item, _no_params, info): return (3, "UNKW - Raidset not found in agent output") -check_info["areca_hba_raidsets"] = { - "check_function" : check_areca_hba_raidsets, - "inventory_function" : inventory_areca_hba_raidsets, - "has_perfdata" : False, - "service_description" : "Raid set %s", - # Find Areca SAS MIB - "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), - "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.4.1.1", - # Below each enclosure there's the following structure for disk data - [ #"2", "4" - "1", # Raidset id - "2", # Raidset name - "4", # Raidset State - "7", # Member disk size - "8", # Member disk names and states - ] - )], -} +# check_info["areca_hba_raidsets"] = { +# "check_function" : check_areca_hba_raidsets, +# "inventory_function" : inventory_areca_hba_raidsets, +# "has_perfdata" : False, +# "service_description" : "Raid set %s", +# # Find Areca SAS MIB +# "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), +# "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.4.1.1", +# # Below each enclosure there's the following structure for disk data +# [ #"2", "4" +# "1", # Raidset id +# "2", # Raidset name +# "4", # Raidset State +# "7", # Member disk size +# "8", # Member disk names and states +# ] +# )], +# } diff --git a/areca/agent_based/areca_hba_temp b/areca/agent_based/areca_hba_temp.py similarity index 91% rename from areca/agent_based/areca_hba_temp rename to areca/agent_based/areca_hba_temp.py index e81f2685..70037608 100644 --- a/areca/agent_based/areca_hba_temp +++ b/areca/agent_based/areca_hba_temp.py @@ -115,13 +115,13 @@ def check_areca_hba_temp(item, params, info): return (3, "UNKNOWN - sensor not found in agent output") -check_info["areca_hba_temp"] = { - "check_function" : check_areca_hba_temp, - "inventory_function" : inventory_areca_hba_temp, - "has_perfdata" : True, - "service_description" : "Temperature %s", - # Find Areca SAS MIB - "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), - "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.2.1.10.1", [ "1", "2", "3" ])], -} +# check_info["areca_hba_temp"] = { +# "check_function" : check_areca_hba_temp, +# "inventory_function" : inventory_areca_hba_temp, +# "has_perfdata" : True, +# "service_description" : "Temperature %s", +# # Find Areca SAS MIB +# "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), +# "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.2.1.10.1", [ "1", "2", "3" ])], +# } diff --git a/areca/agent_based/areca_hba_voltages b/areca/agent_based/areca_hba_voltages.py similarity index 91% rename from areca/agent_based/areca_hba_voltages rename to areca/agent_based/areca_hba_voltages.py index 1fe6a04f..a12f4d9d 100644 --- a/areca/agent_based/areca_hba_voltages +++ b/areca/agent_based/areca_hba_voltages.py @@ -106,13 +106,13 @@ def check_areca_hba_voltages(item, _no_params, info): return (3, "UNKNOWN - Voltage sensor not found in agent output") -check_info["areca_hba_voltages"] = { - "check_function" : check_areca_hba_voltages, - "inventory_function" : inventory_areca_hba_voltages, - "has_perfdata" : True, - "service_description" : "Voltage %s", - # Find Areca SAS MIB - "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), - "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.2.1.8.1", [ "1", "2", "3" ])], -} +# check_info["areca_hba_voltages"] = { +# "check_function" : check_areca_hba_voltages, +# "inventory_function" : inventory_areca_hba_voltages, +# "has_perfdata" : True, +# "service_description" : "Voltage %s", +# # Find Areca SAS MIB +# "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.18928.1"), +# "snmp_info" : [(".1.3.6.1.4.1.18928.1.2.2.1.8.1", [ "1", "2", "3" ])], +# }