Module: check_mk
Branch: master
Commit: 87ac47ce196d1490f8184a63f3482c8fa81090df
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=87ac47ce196d14…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Jan 16 12:11:47 2018 +0100
5648 omd stop/start: Add new option to execute site actions simultaneously
When having a larger number of sites an "omd start" or "omd stop" operation
may take a lot of time since all processes are handles sequentially. To improve
the overall execution time we have now added the optional -p/--parallel arguments
to handle the site actions simultaneously.
Change-Id: Ib9e2f8c00efdcd896be0593f18767dc7d64acfb0
---
.werks/5648 | 17 ++++++
omd/packages/omd/omd | 163 ++++++++++++++++++++++++++++++++++++-------------
omd/packages/omd/omd.8 | 11 +++-
3 files changed, 145 insertions(+), 46 deletions(-)
Diff: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commitdiff;h=87ac47ce19…
Module: check_mk
Branch: master
Commit: 74637c815f2f9324b5113fe6b3f51645b35f395f
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=74637c815f2f93…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Jan 16 10:38:56 2018 +0100
5634 FIX Fixed slowing of CMC stop operation when SNMP checks are running
The Check_MK Microcore may need a long time for completing stop/restart of the
process waiting for currently running operations to finish.
One possible situation was that the Check_MK check helpers currently execute
checks in form of SNMP queries. A common case is that the helpers wait for
the response of a SNMP device which may take up to minutes, depending on the
"SNMP timing settings".
We have now changed the logic that these SNMP queries are terminated which
leads to an immediately ending Check_MK check helper and also a faster ending
Microcore process.
This change is especially important for cluster setups that have a tight
timeout configured for the stop operation of the OMD sites. With this change
the failover situations should be handled a lot faster and more stable.
Change-Id: Ib7f239091ce06c777475ecba762a4fb17c0bcce7
---
.werks/5634 | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/.werks/5634 b/.werks/5634
new file mode 100644
index 0000000..480c093
--- /dev/null
+++ b/.werks/5634
@@ -0,0 +1,24 @@
+Title: Fixed slowing of CMC stop operation when SNMP checks are running
+Level: 2
+Component: core
+Compatible: compat
+Edition: cee
+Version: 1.5.0i3
+Date: 1516095164
+Class: fix
+
+The Check_MK Microcore may need a long time for completing stop/restart of the
+process waiting for currently running operations to finish.
+
+One possible situation was that the Check_MK check helpers currently execute
+checks in form of SNMP queries. A common case is that the helpers wait for
+the response of a SNMP device which may take up to minutes, depending on the
+"SNMP timing settings".
+
+We have now changed the logic that these SNMP queries are terminated which
+leads to an immediately ending Check_MK check helper and also a faster ending
+Microcore process.
+
+This change is especially important for cluster setups that have a tight
+timeout configured for the stop operation of the OMD sites. With this change
+the failover situations should be handled a lot faster and more stable.
Module: check_mk
Branch: master
Commit: 825d97fe6b7655210f67da61805f1a057993dbe3
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=825d97fe6b7655…
Author: Sven Panne <sp(a)mathias-kettner.de>
Date: Fri Jan 12 13:47:51 2018 +0100
Nuke site.pyc, too.
Change-Id: Icecf91bf390e8eb257a465c37c28bec348474544
---
omd/packages/net-snmp/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/omd/packages/net-snmp/Makefile b/omd/packages/net-snmp/Makefile
index 3f57682..de0ffd5 100644
--- a/omd/packages/net-snmp/Makefile
+++ b/omd/packages/net-snmp/Makefile
@@ -43,7 +43,7 @@ install:
# creation of a lib/python/site.py, a copy of site-patch.py from setuptools.
# Having this in the PYTHONPATH makes it impossible to run python3-based SW as a
# site user, including gdb! So let's simply nuke it here...
- $(RM) $(DESTDIR)$(OMD_ROOT)/lib/python/site.py
+ $(RM) $(DESTDIR)$(OMD_ROOT)/lib/python/site.py*
skel:
Module: check_mk
Branch: master
Commit: 3152011085040ef7727d9a4137bb0df13f90fa7b
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=3152011085040e…
Author: Konstantin Büttner <kb(a)mathias-kettner.de>
Date: Fri Jan 12 11:01:39 2018 +0100
5600 hp_fan: New check to monitor the fans of HP switches
Change-Id: I8d22d79444eb9a8c409f32b54c04d841aafa457e
---
.werks/5600 | 10 ++++++++++
checkman/hp_fan | 15 ++++++++++++++
checks/hp_fan | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 86 insertions(+)
diff --git a/.werks/5600 b/.werks/5600
new file mode 100644
index 0000000..4b4871e
--- /dev/null
+++ b/.werks/5600
@@ -0,0 +1,10 @@
+Title: hp_fan: New check to monitor the fans of HP switches
+Level: 1
+Component: checks
+Compatible: compat
+Edition: cre
+Version: 1.5.0i3
+Date: 1515751182
+Class: feature
+
+
diff --git a/checkman/hp_fan b/checkman/hp_fan
new file mode 100644
index 0000000..76b5c50
--- /dev/null
+++ b/checkman/hp_fan
@@ -0,0 +1,15 @@
+title: HP Switches: Fan Status
+agents: SNMP
+catalog: hw/network/hp
+license: GPL
+distribution: check_mk
+description:
+ This check monitors the state of fans in HP switches. "unknown" and "maxstate"
+ are treated as UNKNOWN, "removed" and "off" as CRIT, "underspeed" and "overspeed"
+ as WARN. "ok" is OK.
+
+item:
+ The tray index and the fan index, e.g. 0/3
+
+inventory:
+ One service per fan is created.
diff --git a/checks/hp_fan b/checks/hp_fan
new file mode 100644
index 0000000..2d62072
--- /dev/null
+++ b/checks/hp_fan
@@ -0,0 +1,61 @@
+#!/usr/bin/python
+# -*- encoding: utf-8; py-indent-offset: 4 -*-
+# +------------------------------------------------------------------+
+# | ____ _ _ __ __ _ __ |
+# | / ___| |__ ___ ___| | __ | \/ | |/ / |
+# | | | | '_ \ / _ \/ __| |/ / | |\/| | ' / |
+# | | |___| | | | __/ (__| < | | | | . \ |
+# | \____|_| |_|\___|\___|_|\_\___|_| |_|_|\_\ |
+# | |
+# | Copyright Mathias Kettner 2018 mk(a)mathias-kettner.de |
+# +------------------------------------------------------------------+
+#
+# This file is part of Check_MK.
+# The official homepage is at http://mathias-kettner.de/check_mk.
+#
+# check_mk is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation in version 2. check_mk is distributed
+# in the hope that it will be useful, but WITHOUT ANY WARRANTY; with-
+# out even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE. See the GNU General Public License for more de-
+# tails. You should have received a copy of the GNU General Public
+# License along with GNU Make; see the file COPYING. If not, write
+# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+# Boston, MA 02110-1301 USA.
+
+
+def parse_hp_fan(info):
+ return { "%s/%s" % (tray_index, fan_index) : fan_state for fan_index, tray_index, fan_state in info }
+
+
+def inventory_hp_fan(parsed):
+ for fan in parsed:
+ yield fan, None
+
+
+def check_hp_fan(item, _no_params, parsed):
+ statemap = {
+ "0" : (3, "unknown"),
+ "1" : (2, "removed"),
+ "2" : (2, "off"),
+ "3" : (1, "underspeed"),
+ "4" : (1, "overspeed"),
+ "5" : (0, "ok"),
+ "6" : (3, "maxstate"),
+ }
+ return statemap[parsed[item]]
+
+
+check_info['hp_fan'] = {
+ 'parse_function' : parse_hp_fan,
+ 'inventory_function' : inventory_hp_fan,
+ 'check_function' : check_hp_fan,
+ 'service_description' : 'Fan %s',
+ 'snmp_info' : ('.1.3.6.1.4.1.11.2.14.11.5.1.54.2.1.1', [ # FAN-MIB - hpicfFanEntry
+ OID_END, # HpicfDcFanIndex is not-accessible, so this will have to do.
+ "2", # hpicfFanTray
+ "4", # hpicfFanState
+ ]),
+ 'snmp_scan_function' : lambda oid: "hp" in oid(".1.3.6.1.2.1.1.1.0").lower() and "switch" in oid(".1.3.6.1.2.1.1.1.0").lower(),
+}