summaryrefslogtreecommitdiffstats
path: root/plugins/check_volume_status.py
diff options
context:
space:
mode:
authorSahina Bose <sabose@redhat.com>2014-05-08 12:46:51 +0530
committerSahina Bose <sabose@redhat.com>2014-05-08 02:23:59 -0700
commit9d252a32334a185a717da8990bd6b5e07da97771 (patch)
tree6f198f90a9e724aca481a05354be75567ae2bd2a /plugins/check_volume_status.py
parent5c7a2558334714e55f59ad8c75debe303c420ba4 (diff)
nagios-plugins: Fixed exit status and message for quota plugin
Changed the passive service check to return warning when soft limit exceeded Also corrected the message- if only soft limit exceeded, the message should not contain any entry for hard limit. Change-Id: Ice693997c769d9029825fcd4aafacc45d1577e23 Signed-off-by: Sahina Bose <sabose@redhat.com> Reviewed-on: http://review.gluster.org/7706
Diffstat (limited to 'plugins/check_volume_status.py')
-rwxr-xr-xplugins/check_volume_status.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/check_volume_status.py b/plugins/check_volume_status.py
index 04f3738..ce2b4de 100755
--- a/plugins/check_volume_status.py
+++ b/plugins/check_volume_status.py
@@ -55,7 +55,7 @@ def getVolumeQuotaStatus(args):
return utils.PluginStatusCode.UNKNOWN, out
returnMsg = "QUOTA:"
- if qstatus.get("hard_ex_dirs") is not None:
+ if qstatus.get("hard_ex_dirs"):
hard_limit_ex = ', '.join(qstatus['hard_ex_dirs'])
returnMsg += ("hard limit exceeded on %s; " % hard_limit_ex)
if qstatus.get('soft_ex_dirs'):