Module: check_mk
Branch: master
Commit: f229cb4d75c2f1505aa8a0ad859e39c906d3f765
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f229cb4d75c2f1…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Mon Sep 3 17:21:56 2018 +0200
6484 FIX Fixed filtering check plugins for the management board and the host itself
In order to decide which check is used for which data source
we have to filter the found check plugins. This is done via
the check_info key "management_board". There are three values
with the following meanings:
- MGMT_ONLY
These check plugins
- are only used for management board data sources,
- have the prefix 'mgmt_' in their name,
- have the prefix 'Management Interface:' in their service description.
- If there is an equivalent host check plugin then it must be 'HOST_ONLY'.
- HOST_PRECEDENCE
- Default value for all check plugins.
- It does not have to be declared in the check_info.
- Special situation for SNMP management boards:
- If a host is not a SNMP host these checks are used for
the SNMP management boards.
- If a host is a SNMP host these checks are used for
the host itself.
- HOST_ONLY
These check plugins
- are used for 'real' host data sources, not for host management board data sources
- there is an equivalent 'MGMT_ONLY'-management board check plugin.
Migration from 1.4 to 1.5:
in 1.4 TCP hosts with SNMP management boards discovered TCP and
SNMP checks, eg. uptime and snmp_uptime. During checking phase
these checks should be executed
further on.
In versions >= 1.5 there are management board specific check
plugins, eg. mgmt_snmp_uptime.
After a re-discovery Check_MK finds the uptime check plugin for
the TCP host and the mgmt_snmp_uptime check for the SNMP
management board. Moreover Check_MK eliminates 'HOST_ONLT'
checks like snmp_uptime.
Change-Id: I05290950b6ee3c9abf76e514f1ea6cd19d7dacd9
---
.werks/6484 | 47 +++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/.werks/6484 b/.werks/6484
new file mode 100644
index 0000000..96d10da
--- /dev/null
+++ b/.werks/6484
@@ -0,0 +1,47 @@
+Title: Fixed filtering check plugins for the management board and the host itself
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+Edition: cre
+State: unknown
+Version: 1.6.0i1
+Date: 1535988064
+
+In order to decide which check is used for which data source
+we have to filter the found check plugins. This is done via
+the check_info key "management_board". There are three values
+with the following meanings:
+- MGMT_ONLY
+ These check plugins
+ - are only used for management board data sources,
+ - have the prefix 'mgmt_' in their name,
+ - have the prefix 'Management Interface:' in their service description.
+ - If there is an equivalent host check plugin then it must be 'HOST_ONLY'.
+
+- HOST_PRECEDENCE
+ - Default value for all check plugins.
+ - It does not have to be declared in the check_info.
+ - Special situation for SNMP management boards:
+ - If a host is not a SNMP host these checks are used for
+ the SNMP management boards.
+ - If a host is a SNMP host these checks are used for
+ the host itself.
+
+- HOST_ONLY
+ These check plugins
+ - are used for 'real' host data sources, not for host management board data sources
+ - there is an equivalent 'MGMT_ONLY'-management board check plugin.
+
+
+Migration from 1.4 to 1.5:
+in 1.4 TCP hosts with SNMP management boards discovered TCP and
+SNMP checks, eg. uptime and snmp_uptime. During checking phase
+these checks should be executed
+further on.
+In versions >= 1.5 there are management board specific check
+plugins, eg. mgmt_snmp_uptime.
+After a re-discovery Check_MK finds the uptime check plugin for
+the TCP host and the mgmt_snmp_uptime check for the SNMP
+management board. Moreover Check_MK eliminates 'HOST_ONLT'
+checks like snmp_uptime.
Module: check_mk
Branch: master
Commit: f2b2f4d426685a39a76ecf97749335ce199797b9
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f2b2f4d426685a…
Author: Sven Panne <sp(a)mathias-kettner.de>
Date: Mon Sep 3 15:33:57 2018 +0200
6501 FIX Warn during config generation when an unknown timeperiod from a shadow host is encountered.
When a shadow host uses a timeperiod which is unknown on the master site, we
issue a warning during config generation time ("cmk -U" etc.) now. We
substitute the timeperiod "24X7" (i.e. "Always") in these cases.
Change-Id: I2c2dff4d1eb5823786091e93d515e53b50009578
---
.werks/6501 | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/.werks/6501 b/.werks/6501
new file mode 100644
index 0000000..0656e56
--- /dev/null
+++ b/.werks/6501
@@ -0,0 +1,13 @@
+Title: Warn during config generation when an unknown timeperiod from a shadow host is encountered.
+Level: 1
+Component: config
+Class: fix
+Compatible: compat
+Edition: cee
+State: unknown
+Version: 1.6.0i1
+Date: 1535982946
+
+When a shadow host uses a timeperiod which is unknown on the master site, we
+issue a warning during config generation time ("cmk -U" etc.) now. We
+substitute the timeperiod "24X7" (i.e. "Always") in these cases.
Module: check_mk
Branch: master
Commit: 52e0bb8f12e2594a9aaebbfd23669507799e91e0
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=52e0bb8f12e259…
Author: Sven Panne <sp(a)mathias-kettner.de>
Date: Mon Sep 3 12:37:50 2018 +0200
Abort when an unknown timeperiod is used.
This should never happen, and it is better to terminate with a sensible log
message than to crash later at an unknown moment.
Some const-correctness fixes on the way.
Change-Id: Ibb734dc9ac79d084f375072559e7d9d1534f4464
---
livestatus/src/HostSpecialDoubleColumn.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/livestatus/src/HostSpecialDoubleColumn.cc b/livestatus/src/HostSpecialDoubleColumn.cc
index e8b33be..02a680f 100644
--- a/livestatus/src/HostSpecialDoubleColumn.cc
+++ b/livestatus/src/HostSpecialDoubleColumn.cc
@@ -64,7 +64,7 @@ double HostSpecialDoubleColumn::getValue(Row row) const {
double HostSpecialDoubleColumn::staleness(const Object *object) {
auto state = object->state();
std::chrono::system_clock::duration check_result_age;
- Timeperiod *check_period = object->_check_period;
+ const Timeperiod *check_period = object->_check_period;
std::chrono::system_clock::time_point last_period_change =
check_period->lastStateChange();
std::chrono::system_clock::time_point last_check = state->_last_check;
Module: check_mk
Branch: master
Commit: 2b5b9d6cfd84b80bab7eadfee852bd1561962d03
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=2b5b9d6cfd84b8…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Sep 3 16:13:09 2018 +0200
Fixed longer existing issue while disabling TMPFS using the re-added TMPFS config hook
The TMPFS option was not set to "off". Instead it was set to a config
value "Cleaning up temp filesystem...OK" because the hooks set mode
produced this output when working as expected.
Change-Id: Ic0a990d2f25209e2806edcf0b666dfbe22e87c34
---
omd/packages/omd/TMPFS.hook | 2 +-
omd/packages/omd/omd | 5 +++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/omd/packages/omd/TMPFS.hook b/omd/packages/omd/TMPFS.hook
index 350221d..0ee379e 100755
--- a/omd/packages/omd/TMPFS.hook
+++ b/omd/packages/omd/TMPFS.hook
@@ -19,7 +19,7 @@ case "$1" in
set)
# Unmount the tmpfs when it was mounted before
if [ "$2" == "off" ]; then
- omd umount
+ omd umount >/dev/null
fi
;;
esac
diff --git a/omd/packages/omd/omd b/omd/packages/omd/omd
index ede9538..ea8da3e 100644
--- a/omd/packages/omd/omd
+++ b/omd/packages/omd/omd
@@ -1595,11 +1595,12 @@ def prepare_tmpfs(sitename, tmp):
return # Fine: Mounted
if g_site_conf["TMPFS"] != "on":
+ sys.stdout.write("Preparing tmp directory %s..." % tmp)
+ sys.stdout.flush()
+
if os.path.exists(tmp):
return
- sys.stdout.write("Preparing tmp directory %s..." % tmp)
- sys.stdout.flush()
try:
os.mkdir(tmp)
except OSError, e:
Module: check_mk
Branch: master
Commit: 8f4c04a05a877385a7fb85b0c554abf3a599085b
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=8f4c04a05a8773…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Sep 3 16:01:30 2018 +0200
6530 FIX Fixed possible error "You can not override a builtin auxiliary tag" after update
During the tag migration from 1.5 or newer a problem could happen that
the auxiliary tags "snmp" and "tcp" were not removed correctly. This
happened when the titles of these auxiliary tags have been changed in
the site.
Workaround with 1.5.0p2 or older: Have a look at the
/omd/sites/[SITE]/etc/check_mk/multisite.d/wato/hosttags.mk file. First
create a backup of this file, then look for entries like this:
wato_aux_tags += \
[('snmp', u'monitor via SNMP'), ('tcp', u'monitor via Check_MK Agent')]
Try to remove the line and reload the GUI. The issue should be gone now.
Change-Id: Ie3adf0c35c405cf21a80ac14dc630bd351c19f52
---
.werks/6530 | 24 ++++++++++++++++++++++++
cmk/gui/config.py | 12 +++++-------
2 files changed, 29 insertions(+), 7 deletions(-)
diff --git a/.werks/6530 b/.werks/6530
new file mode 100644
index 0000000..5e3b910
--- /dev/null
+++ b/.werks/6530
@@ -0,0 +1,24 @@
+Title: Fixed possible error "You can not override a builtin auxiliary tag" after update
+Level: 1
+Component: multisite
+Class: fix
+Compatible: compat
+Edition: cre
+State: unknown
+Version: 1.6.0i1
+Date: 1535963347
+
+During the tag migration from 1.5 or newer a problem could happen that the auxiliary
+tags "snmp" and "tcp" were not removed correctly. This happened when the titles of these
+auxiliary tags have been changed in the site.
+
+This is a regression since 1.5.0p1 (caused by #6247).
+
+Workaround with 1.5.0p2 or older: Have a look at the
+/omd/sites/[SITE]/etc/check_mk/multisite.d/wato/hosttags.mk file. First create
+a backup of this file, then look for entries like this:
+
+wato_aux_tags += \
+[('snmp', u'monitor via SNMP'), ('tcp', u'monitor via Check_MK Agent')]
+
+Try to remove the line and reload the GUI. The issue should be gone now.
diff --git a/cmk/gui/config.py b/cmk/gui/config.py
index 3a75b74..5e81451 100644
--- a/cmk/gui/config.py
+++ b/cmk/gui/config.py
@@ -845,16 +845,14 @@ def remove_old_sample_config_tag_groups(host_tags, aux_tags):
except ValueError:
pass # Not there or modified
- legacy_aux_tags = [
- ('snmp', u'monitor via SNMP'),
- ('tcp', u'monitor via Check_MK Agent'),
+ legacy_aux_tag_ids = [
+ 'snmp',
+ 'tcp',
]
- for aux_tag in legacy_aux_tags:
- try:
+ for aux_tag in aux_tags[:]:
+ if aux_tag[0] in legacy_aux_tag_ids:
aux_tags.remove(aux_tag)
- except ValueError:
- pass # Not there or modified
def extend_user_modified_tag_groups(host_tags):
Module: check_mk
Branch: master
Commit: 93f1aafce25884353d6ede4697eb35acf77fd2c0
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=93f1aafce25884…
Author: Marcel Arentz <ma(a)mathias-kettner.de>
Date: Mon Sep 3 15:46:27 2018 +0200
Just added an example for an inventory configuration file
Change-Id: I89f86152ffc29eba8a1e1cff908fffba55eedfa1
---
agents/cfg_examples/mk_inventory.cfg | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
diff --git a/agents/cfg_examples/mk_inventory.cfg b/agents/cfg_examples/mk_inventory.cfg
new file mode 100644
index 0000000..09bd55a
--- /dev/null
+++ b/agents/cfg_examples/mk_inventory.cfg
@@ -0,0 +1,32 @@
+# +------------------------------------------------------------------+
+# | ____ _ _ __ __ _ __ |
+# | / ___| |__ ___ ___| | __ | \/ | |/ / |
+# | | | | '_ \ / _ \/ __| |/ / | |\/| | ' / |
+# | | |___| | | | __/ (__| < | | | | . \ |
+# | \____|_| |_|\___|\___|_|\_\___|_| |_|_|\_\ |
+# | |
+# | Copyright Mathias Kettner 2014 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.
+
+
+### Configuration examples for the inventory plugin on Linux and
+### Solaris.
+
+# The inventory plugin will cache the output 14400 seconds by default
+# on the Check_MK server. You can change this value here:
+
+#INVENTORY_INTERVALL=14400