Module: check_mk
Branch: master
Commit: 338bc0d16ab2eaa26a798fbaa6962b5a412832b9
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=338bc0d16ab2ea…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Apr 9 15:21:40 2014 +0200
Small update of manpage of brocade_fcport
---
checkman/brocade_fcport | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/checkman/brocade_fcport b/checkman/brocade_fcport
index 4f52495..8e5b950 100644
--- a/checkman/brocade_fcport
+++ b/checkman/brocade_fcport
@@ -17,12 +17,16 @@ description:
{[3]} An error counter exceeds its configured levels (CRC errors, Enc-OUT
frames, no Tx credits, C3 discards)
- {Averaging}: This check supports averaging on all counters. Averaging is
+ Averaging: This check supports averaging on all counters. Averaging is
turned on but setting the check parameter {"average"} to a number of minutes.
In that case the check produces additional performance data for each parameter
and all warning/error levels are only applied on the averaged value, not on
the current one. This is especially helpful when using levels on the throughput.
+ Note: The counters CRC errors and Enc-OUT are represented as percentages in
+ relation to the number of received frames. C3 discards and no Tx credits are
+ in relation to the number of sent frames.
+
item:
The item is the port-number as two-digit or three-digit string (on switches
with 100 or more ports) as printed on the switch (note: the SNMP-index of
Module: check_mk
Branch: master
Commit: 8242786b8d2d30fda29ce09c5e839e3dd786cbcc
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=8242786b8d2d30…
Author: Bastian Kuhn <bk(a)mathias-kettner.de>
Date: Wed Apr 9 14:40:55 2014 +0200
f5_bigip_cluster: fixed inventory function
---
checks/f5_bigip_cluster | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/checks/f5_bigip_cluster b/checks/f5_bigip_cluster
index 34f5e32..874379d 100644
--- a/checks/f5_bigip_cluster
+++ b/checks/f5_bigip_cluster
@@ -35,8 +35,8 @@
def inventory_f5_bigip_cluster(info):
# run inventory unless we found a device in unconfigured state
- # don't need to loop over the input as there's only one status.
- if len(info) == 1 and not info[0][0].startswith("-1"):
+ # don't need to loop over the input as there's only one status
+ if len(info) == 1 and not ( info[0][0].startswith("-1") or info[0][0] == '' ):
return [(None, None)]
return []
Module: check_mk
Branch: master
Commit: ff354002d0d69998e33459267a327e6fc1bc328f
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=ff354002d0d699…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Apr 9 12:54:03 2014 +0200
windows_tasks: output last and next run time
---
.werks/879 | 8 ++++++++
ChangeLog | 3 ++-
checks/windows_tasks | 29 ++++++++++++++++++-----------
3 files changed, 28 insertions(+), 12 deletions(-)
diff --git a/.werks/879 b/.werks/879
new file mode 100644
index 0000000..58ea5db
--- /dev/null
+++ b/.werks/879
@@ -0,0 +1,8 @@
+Title: windows_tasks: output last and next run time
+Level: 1
+Component: checks
+Version: 1.2.5i3
+Date: 1397040831
+Class: feature
+
+
diff --git a/ChangeLog b/ChangeLog
index d064fba..b4f7ed5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -18,14 +18,15 @@
* 0602 cmciii.humidity: new check for Rittals CMC III humidity sensors
* 0829 oracle_tablespaces: improved formatting of levels text in check output...
* 0757 Linux multipath check can now use the alias instead of the UUID as item...
+ * 0879 windows_tasks: output last and next run time
* 0777 FIX: special agent emcvnx: did not work with security file authentication...
* 0786 FIX: zfsget: fixed compatibility with older Solaris agents...
* 0809 FIX: brocade_fcport: Fixed recently introduced problem with port speed detection
* 0787 FIX: df: fixed problems on some filesystem checks when legacy check parameters where used...
- * 0603 FIX: cmciii checks: more general scan function plus perf-o-meters for humidity and temperature checks
* 0803 FIX: agent_ibmsvc: raw data for System Info Check and License Check now in correct format...
* 0788 FIX: oracle_tablespaces: now able to bear None values as warn/crit levels...
* 0789 FIX: oracle_tablespaces: fixed bug when using dynamic filesystem levels...
+ * 0603 FIX: cmciii checks: more general scan function plus perf-o-meters for humidity and temperature checks
Multisite:
* 0779 Hostgroups (Summary): Empty hostgroups are no longer shown (can be re-enabled by filter)
diff --git a/checks/windows_tasks b/checks/windows_tasks
index 7aec0c7..46aca6b 100644
--- a/checks/windows_tasks
+++ b/checks/windows_tasks
@@ -25,17 +25,18 @@
# Boston, MA 02110-1301 USA.
# Example output from agent:
-#TaskName : \WebShopPictureUpload
-#Last Run Time : 17.10.2013 23:00:00
-#Next Run Time : 18.10.2013 23:00:00
-#Last Result : 0
-#Scheduled Task State : Enabled
+# <<<windows_tasks:sep(58)>>>
+# TaskName : \WebShopPictureUpload
+# Last Run Time : 17.10.2013 23:00:00
+# Next Run Time : 18.10.2013 23:00:00
+# Last Result : 0
+# Scheduled Task State : Enabled
#
-#TaskName : \OfficeSoftwareProtectionPlatform\SvcRestartTask
-#Last Run Time : N/A
-#Next Run Time : Disabled
-#Last Result : 1
-#Scheduled Task State : Disabled
+# TaskName : \OfficeSoftwareProtectionPlatform\SvcRestartTask
+# Last Run Time : N/A
+# Next Run Time : Disabled
+# Last Result : 1
+# Scheduled Task State : Disabled
def windows_tasks_convert(info):
@@ -43,7 +44,7 @@ def windows_tasks_convert(info):
last_task = False
for line in info:
name = line[0].strip()
- value = "".join(line[1:]).strip()
+ value = ":".join(line[1:]).strip()
if last_task and name != "TaskName":
data[last_task][name] = value
@@ -73,6 +74,12 @@ def check_windows_tasks(item, _no_params, info):
msg.append("Task not Enabled(!!)")
state = 2
+ if "Last Run Time" in values:
+ msg.append("last run time: %s" % values["Last Run Time"])
+
+ if "Next Run Time" in values:
+ msg.append("next run time: %s" % values["Next Run Time"])
+
return state, ", ".join(msg)
return 3, "Task not found on server"
Module: check_mk
Branch: master
Commit: cff9d866636c5e555e10e137bec995796161797c
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=cff9d866636c5e…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Apr 8 12:20:55 2014 +0200
Linux multipath check can now use the alias instead of the UUID as item
If you have set useful aliasses for you Linux multipath devices then you can
now have Check_MK use these instead of the UUIDs for the service description.
This makes alerting, BI aggregates and other stuff easier. The configuration
is via a new rule set <i>Linux Multipath Inventory</i>. If you are now using
WATO then please refer to the check's man page for details.
---
.werks/757 | 12 ++++++++++++
ChangeLog | 1 +
checkman/multipath | 13 ++++++++++++-
checks/multipath | 18 ++++++++++++++++--
web/plugins/wato/check_parameters.py | 19 +++++++++++++++++++
5 files changed, 60 insertions(+), 3 deletions(-)
diff --git a/.werks/757 b/.werks/757
new file mode 100644
index 0000000..5bc19d1
--- /dev/null
+++ b/.werks/757
@@ -0,0 +1,12 @@
+Title: Linux multipath check can now use the alias instead of the UUID as item
+Level: 2
+Component: checks
+Version: 1.2.5i3
+Date: 1396952369
+Class: feature
+
+If you have set useful aliasses for you Linux multipath devices then you can
+now have Check_MK use these instead of the UUIDs for the service description.
+This makes alerting, BI aggregates and other stuff easier. The configuration
+is via a new rule set <i>Linux Multipath Inventory</i>. If you are now using
+WATO then please refer to the check's man page for details.
diff --git a/ChangeLog b/ChangeLog
index 05ade8e..91d1403 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -16,6 +16,7 @@
NOTE: Please refer to the migration notes!
* 0802 ibm_svc_nodestats.iops, ibm_svc_systemstats.iops: new checks for IO operations/sec on IBM SVC / V7000 devices
* 0602 cmciii.humidity: new check for Rittals CMC III humidity sensors
+ * 0757 Linux multipath check can now use the alias instead of the UUID as item...
* 0777 FIX: special agent emcvnx: did not work with security file authentication...
* 0786 FIX: zfsget: fixed compatibility with older Solaris agents...
* 0809 FIX: brocade_fcport: Fixed recently introduced problem with port speed detection
diff --git a/checkman/multipath b/checkman/multipath
index 0543f80..7b4a13d 100644
--- a/checkman/multipath
+++ b/checkman/multipath
@@ -24,9 +24,20 @@ item:
alias as item.
inventory:
- One check for each multipath device is created.
+ One check for each multipath device is created. Via {iventory_multipath_rules}
+ you can specify wether an alias should be used as item instead of the UUID.
+
+examples:
+ # Use the alias as item if one is being set
+ inventory_multipath_rules = [
+ ( {'use_alias': True}, [], ALL_HOSTS ),
+ ]
+
[parameters]
numpaths(int): The only parameter is the number of expected paths. This is not
a tuple but a simple integer value.
+[configuration]
+inventory_multipath_rules(ruleset): A dictionary ruleset with currently the only possible
+ key being {use_alias}. See section inventory for details.
diff --git a/checks/multipath b/checks/multipath
index 6457f69..5247647 100644
--- a/checks/multipath
+++ b/checks/multipath
@@ -24,6 +24,8 @@
# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
# Boston, MA 02110-1301 USA.
+# Configuration for using alias instead of UUID
+inventory_multipath_rules = []
# Output from multipath -l has the following format:
@@ -252,11 +254,17 @@ def parse_multipath_output(info, only_uuid = None):
# Get list of UUIDs of all multipath devices
# Length of UUID is 360a9800043346937686f456f59386741
def inventory_multipath(info):
+ settings = host_extra_conf_merged(g_hostname, inventory_multipath_rules)
+
inventory = []
parsed = parse_multipath_output(info)
for uuid, info in parsed.items():
# take current number of paths as target value
- inventory.append( (uuid, " ".join(info['luns']), info['numpaths']) )
+ if "alias" in info and settings.get("use_alias"):
+ item = info["alias"]
+ else:
+ item = uuid
+ inventory.append( (item, info['numpaths']) )
return inventory
# item is UUID (e.g. '360a9800043346937686f456f59386741') or alias (e.g. 'mpath0')
@@ -269,9 +277,15 @@ def check_multipath(item, target_numpaths, info):
return (3, "no map with uuid/alias %s" % item)
mmap = parsed.values()[0]
+ # If the item is the alias, then show the UUID in the plugin output.
+ # If the item is the UUID, then vice versa.
alias = mmap.get('alias')
- if alias:
+ uuid = mmap.get('uuid')
+
+ if item == uuid and alias:
aliasinfo = "(%s) " % alias
+ elif item == alias and uuid:
+ aliasinfo = "(%s) " % uuid
else:
aliasinfo = ""
diff --git a/web/plugins/wato/check_parameters.py b/web/plugins/wato/check_parameters.py
index 2d2c845..3b6d28f 100644
--- a/web/plugins/wato/check_parameters.py
+++ b/web/plugins/wato/check_parameters.py
@@ -3437,6 +3437,25 @@ register_check_parameters(
"first"
)
+register_rule(
+ "checkparams/" + subgroup_storage,
+ varname = "inventory_multipath_rules",
+ title = _("Linux Multipath Inventory"),
+ valuespec = Dictionary(
+ elements = [
+ ("use_alias", Checkbox(
+ title = _("Use the multipath alias as service name, if one is set"),
+ label = _("use alias"),
+ help = _("If a multipath device has an alias then you can use that for specifying "
+ "the device instead of the UUID. The alias will then be part of the service "
+ "description. The UUID will be output in the pluging outpout."))
+ ),
+ ],
+ help = _('This rule controls the inventory of Multipath devices on Linux.'),
+ ),
+ match = 'dict',
+)
+
register_check_parameters(
subgroup_storage,
"multipath_count",