mirror of
https://github.com/valitydev/ceph-nagios-plugins.git
synced 2024-11-06 08:45:17 +00:00
print performance data for pools
This commit is contained in:
parent
c29c2743f4
commit
3e66285dbb
@ -125,13 +125,13 @@ def main():
|
||||
pool_objects = float(poolvals[5])
|
||||
|
||||
if pool_usage_percent > args.critical:
|
||||
print 'CRITICAL: Pool \'%s\' usage of %s%% is above %s%% (%s used)' % (args.pool, pool_usage_percent, args.critical, pool_used)
|
||||
print 'CRITICAL: %s%% usage in Pool \'%s\' is above %s%% (%s used) | Usage=%s%%;%s;%s;;' % (pool_usage_percent, args.pool, args.critical, pool_used, pool_usage_percent, args.warn, args.critical)
|
||||
return STATUS_ERROR
|
||||
if pool_usage_percent > args.warn:
|
||||
print 'WARNING: Pool \'%s\' usage of %s%% is above %s%% (%s used)' % (args.pool, pool_usage_percent, args.warn, pool_used)
|
||||
print 'WARNING: %s%% usage in Pool \'%s\' is above %s%% (%s used) | Usage=%s%%;%s;%s;;' % (pool_usage_percent, args.pool, args.warn, pool_used, pool_usage_percent, args.warn, args.critical)
|
||||
return STATUS_WARNING
|
||||
else:
|
||||
print 'Pool \'%s\' usage %s%%' % (args.pool, pool_usage_percent)
|
||||
print '%s%% usage in Pool \'%s\' | Usage=%s%%;%s;%s;;' % (pool_usage_percent, args.pool, pool_usage_percent, args.warn, args.critical)
|
||||
return STATUS_OK
|
||||
else:
|
||||
# print 'DEBUG:', globalvals
|
||||
|
Loading…
Reference in New Issue
Block a user