summaryrefslogtreecommitdiffstats
path: root/plugins/check_gluster_syslog.py
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/check_gluster_syslog.py')
-rwxr-xr-xplugins/check_gluster_syslog.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/plugins/check_gluster_syslog.py b/plugins/check_gluster_syslog.py
index e71647a..d83e302 100755
--- a/plugins/check_gluster_syslog.py
+++ b/plugins/check_gluster_syslog.py
@@ -37,13 +37,6 @@ def findVolName(pattern):
return pattern[pattern.find('-') + 1:pattern.rfind('-')]
-def getStatusCode(alertlevel):
- if alertlevel == 'ALERT':
- return utils.PluginStatusCode.CRITICAL
- else:
- return utils.PluginStatusCode.WARNING
-
-
def processQuotaMsg(msg, alertlevel):
quotapat = re.compile(r'\b\d*-[a-zA-Z0-9_-]*-quota\b')
matches = quotapat.search(msg)
@@ -55,7 +48,7 @@ def processQuotaMsg(msg, alertlevel):
serviceName = nscautils.vol_service_name(volname, "Quota")
nscautils.send_to_nsca_subproc(nscautils.getNagiosClusterName(),
serviceName,
- getStatusCode(alertlevel),
+ utils.PluginStatusCode.WARNING,
alertMsg)