Module: check_mk
Branch: master
Commit: 9b658686d032654adacbdcac91d6237393bf24df
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=9b658686d03265…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Fri Sep 11 11:30:30 2015 +0200
new option 'Storage Processor Utilization' in agent_emcvnx
---
agents/special/agent_emcvnx | 19 ++++++++++++-------
web/plugins/wato/datasource_programs.py | 1 +
2 files changed, 13 insertions(+), 7 deletions(-)
diff --git a/agents/special/agent_emcvnx b/agents/special/agent_emcvnx
index 319a859..c077417 100755
--- a/agents/special/agent_emcvnx
+++ b/agents/special/agent_emcvnx
@@ -103,11 +103,12 @@ mortypes = [ 'all' ]
fetch_agent_info = False
naviseccli_options = {
- "disks" : {"cmd_option" : "-disk",
"active" : False},
- "hba" : {"cmd_option" : "-hba",
"active" : False},
- "hwstatus" : {"cmd_option" : "-array",
"active" : False},
- "raidgroups" : {"cmd_option" : "-rg",
"active" : False},
-# "agent-info" : {"cmd_option" : "-sp",
"active" : False},
+ "disks" : {"cmd_option" : "getall -disk",
"active" : False, "sep" : None},
+ "hba" : {"cmd_option" : "getall -hba",
"active" : False, "sep" : None},
+ "hwstatus" : {"cmd_option" : "getall -array",
"active" : False, "sep" : None},
+ "raidgroups" : {"cmd_option" : "getall -rg",
"active" : False, "sep" : None},
+# "agent-info" : {"cmd_option" : "-sp",
"active" : False, "sep" : None},
+ "sp_util" : {"cmd_option" : "getcontrol -cbt",
"active" : False, "sep" : 58},
}
for o,a in opts:
@@ -212,8 +213,12 @@ if fetch_agent_info:
#
for module in naviseccli_options.keys():
if naviseccli_options[module]["active"] == True:
- print "<<<emcvnx_%s>>>" % module
- cmd=basecmd + "getall " +
naviseccli_options[module]["cmd_option"]
+ separator = naviseccli_options[module]["sep"]
+ if separator:
+ print "<<<emcvnx_%s:sep(%s)>>>" % (module,
separator)
+ else:
+ print "<<<emcvnx_%s>>>" % module
+ cmd=basecmd + naviseccli_options[module]["cmd_option"]
if opt_debug:
sys.stderr.write("executing external command: %s\n" % cmd)
for line in os.popen(cmd).readlines():
diff --git a/web/plugins/wato/datasource_programs.py
b/web/plugins/wato/datasource_programs.py
index 9981da3..2dd07dc 100644
--- a/web/plugins/wato/datasource_programs.py
+++ b/web/plugins/wato/datasource_programs.py
@@ -304,6 +304,7 @@ register_rule(group,
( "hwstatus", _("Hardware Status") ),
( "raidgroups", _("RAID Groups") ),
( "agent", _("Model and Revsion")
),
+ ( "sp_util", _("Storage Processor
Utilization") ),
],
default_value = [ "disks", "hba",
"hwstatus", ],
allow_empty = False,