Module: check_mk
Branch: master
Commit: e8951ed06a41b184015aa8c195eacdda56cfa2f3
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=e8951ed06a41b1…
Author: Marcel Schulte <ms(a)mathias-kettner.de>
Date: Wed Dec 28 12:33:03 2016 +0100
4120 FIX fixed checks mysql and mysql.sessions for multiple MySQL instances
Previously only one mysql (version) and mysql.sessions check was created. This has been
fixed now.
Change-Id: I2d19502b7a79fa62ba08f1f5b1df0b8d9e1b6c86
---
.werks/4120 | 10 ++++++++++
ChangeLog | 1 +
checks/mysql | 4 ++--
3 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/.werks/4120 b/.werks/4120
new file mode 100644
index 0000000..f5fa4fe
--- /dev/null
+++ b/.werks/4120
@@ -0,0 +1,10 @@
+Title: fixed checks mysql and mysql.sessions for multiple MySQL instances
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.4.0i4
+Date: 1482924646
+
+Previously only one mysql (version) and mysql.sessions check was created. This has been
fixed now.
diff --git a/ChangeLog b/ChangeLog
index cd258ec..6aade15 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -18,6 +18,7 @@
* 4006 FIX: Windows Agent: Fixed possible memory leak when using logwatch with vista
api setting
* 4008 FIX: Windows Agent, dotnet_clrmemory section: prevent indefinite freeze of
windows agent...
* 4209 FIX: mk_jolokia: Setting a default product now works...
+ * 4120 FIX: fixed checks mysql and mysql.sessions for multiple MySQL instances...
Multisite:
* 4169 View action: Default values of sticky, notification and persistent options can
now be configured via global settings....
diff --git a/checks/mysql b/checks/mysql
index 581bfeb..42d68c6 100644
--- a/checks/mysql
+++ b/checks/mysql
@@ -51,7 +51,7 @@
def inventory_mysql(parsed):
for instance, values in parsed.items():
if len(values.keys()) > 200: # should be at least 321 line
- return [(instance, {})]
+ yield instance, {}
# FIXME: Crapy copy n paste! Consolidate with other mysql_* parse functions
def parse_mysql(info):
@@ -91,7 +91,7 @@ def parse_mysql(info):
def inventory_mysql_version(parsed):
for instance, values in parsed.items():
if 'version' in values:
- return [(instance, {})]
+ yield instance, {}
def check_mysql_version(item, _no_params, parsed):
if item in parsed: