Module: check_mk
Branch: master
Commit: 486ffb96c5bb711a772ddc19599e76d71bf82fc9
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=486ffb96c5bb71…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Thu Aug 11 15:57:14 2016 +0200
3784 agent_netapp / 7mode: now also reports snapsvaults for the default filer
Previously only vfiler specific snapvaults were reported
---
.werks/3784 | 9 +++++++++
ChangeLog | 1 +
agents/special/agent_netapp | 30 +++++++++++++++---------------
3 files changed, 25 insertions(+), 15 deletions(-)
diff --git a/.werks/3784 b/.werks/3784
new file mode 100644
index 0000000..7c72216
--- /dev/null
+++ b/.werks/3784
@@ -0,0 +1,9 @@
+Title: agent_netapp / 7mode: now also reports snapsvaults for the default filer
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.4.0i1
+Date: 1470923754
+Class: feature
+
+Previously only vfiler specific snapvaults were reported
diff --git a/ChangeLog b/ChangeLog
index 7173e95..3e5c27d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -125,6 +125,7 @@
* 3712 ispro_sensors_temp, ispro_sensors_humid, ispro_sensors_digital: new checks
which monitor Interseptro Pro devices which support the ISPRO-MIB
* 3560 emcvnx_disks: now able to configure states for hard read/write errors and when
enclosure rebuilds
* 3783 netapp_api_qtree_quota: new check to monitor disk usage of qtrees
+ * 3784 agent_netapp / 7mode: now also reports snapsvaults for the default filer...
* 3073 FIX: windows agent: relative paths to mrpe scripts are now treated as relative
to the agent installation directory...
* 3061 FIX: mk_jolokia: Fixed debugging of the agent plugin
* 3074 FIX: windows agent: fixed incorrect values for 32-bit performance counters
diff --git a/agents/special/agent_netapp b/agents/special/agent_netapp
index 4fa3d19..d27f5c1 100755
--- a/agents/special/agent_netapp
+++ b/agents/special/agent_netapp
@@ -778,7 +778,7 @@ else:
# VFiler
vfiler_info = query("vfiler-list-info")
- vfiler_names = []
+ vfiler_names = [""] # default is no vfiler
if vfiler_info:
print "<<<netapp_api_vf_status:sep(9)>>>"
for vfiler in vfiler_info.children_get():
@@ -788,20 +788,20 @@ else:
print "%s\t%s" % (name,
response.child_get_string("status"))
# Snapvaults
- if vfiler_names:
- print "<<<netapp_api_snapvault:sep(9)>>>"
- for vfiler in vfiler_names:
- server.set_vfiler(vfiler)
- response =
server.invoke("snapvault-secondary-relationship-status-list-iter-start")
- records = response.child_get_string("records")
- if not records or records == "0":
- continue
- tag = response.child_get_string("tag")
- response =
server.invoke("snapvault-secondary-relationship-status-list-iter-next",
"maximum", records, "tag", tag)
- print format_config(response.child_get("status-list"),
"snapvault", "source-path",
- config_report = ["lag-time",
"state", "status", "source-system",
"destination-system"])
-
server.invoke("snapvault-secondary-relationship-status-list-iter-end","tag",
tag)
- server.set_vfiler("")
+ print "<<<netapp_api_snapvault:sep(9)>>>"
+ for vfiler in vfiler_names:
+ server.set_vfiler(vfiler)
+ response =
server.invoke("snapvault-secondary-relationship-status-list-iter-start")
+ records = response.child_get_string("records")
+ if not records or records == "0":
+ continue
+ tag = response.child_get_string("tag")
+ response =
server.invoke("snapvault-secondary-relationship-status-list-iter-next",
"maximum", records, "tag", tag)
+ print format_config(response.child_get("status-list"),
"snapvault", "source-path",
+ config_report = ["lag-time", "state",
"status", "source-system", "destination-system"])
+
server.invoke("snapvault-secondary-relationship-status-list-iter-end","tag",
tag)
+ server.set_vfiler("") # revert back to default (no) vfiler
+
# VFiler Counters
vfiler_counters = query_counters("vfiler")