Add additional faults

This commit is contained in:
Joshua Boniface 2023-12-06 13:27:39 -05:00
parent 6fc5c927a1
commit 4a02c2c8e3
1 changed files with 17 additions and 5 deletions

View File

@ -307,10 +307,16 @@ class MonitoringInstance(object):
# This is a list of all possible faults (cluster error messages) and their corresponding details # This is a list of all possible faults (cluster error messages) and their corresponding details
self.cluster_faults_map = { self.cluster_faults_map = {
"unhealthy_node": { "unhealthy_node": {
"entries": get_node_health_states,
"conditions": range(90, 51, -1),
"delta": 10,
"message": "Node {entry} health",
},
"very_unhealthy_node": {
"entries": get_node_health_states, "entries": get_node_health_states,
"conditions": range(50, 0, -1), "conditions": range(50, 0, -1),
"delta": 0, "delta": 50,
"message": "Node {entry} <= 50% health", "message": "Node {entry} health",
}, },
"dead_or_fenced_node": { "dead_or_fenced_node": {
"entries": get_node_daemon_states, "entries": get_node_daemon_states,
@ -321,12 +327,18 @@ class MonitoringInstance(object):
"ceph_osd_out": { "ceph_osd_out": {
"entries": get_osd_in_states, "entries": get_osd_in_states,
"conditions": ["0"], "conditions": ["0"],
"delta": 25, "delta": 50,
"message": "OSD {entry} was marked out", "message": "OSD {entry} was marked out",
}, },
"ceph_warn": {
"entries": get_ceph_health_entries,
"conditions": ["HEALTH_WARN"],
"delta": 10,
"message": "{entry} reported by Ceph ({details})",
},
"ceph_err": { "ceph_err": {
"entries": get_ceph_health_entries, "entries": get_ceph_health_entries,
"conditions": ["HEALTH_ERR", "HEALTH_WARN"], "conditions": ["HEALTH_ERR"],
"delta": 50, "delta": 50,
"message": "{entry} reported by Ceph ({details})", "message": "{entry} reported by Ceph ({details})",
}, },
@ -339,7 +351,7 @@ class MonitoringInstance(object):
"memory_overprovisioned": { "memory_overprovisioned": {
"entries": get_overprovisioned_memory, "entries": get_overprovisioned_memory,
"conditions": ["overprovisioned"], "conditions": ["overprovisioned"],
"delta": 25, "delta": 50,
"message": "Cluster memory was overprovisioned {entry}", "message": "Cluster memory was overprovisioned {entry}",
}, },
} }