Module: check_mk
Branch: master
Commit: e58cd3d1b46fe0bb572cbc84e290a7d406100c49
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=e58cd3d1b46fe0…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Dec 16 16:23:37 2013 +0100
sms: now searching PATH for sendsms and smssend commands
In previous versions the notification plugin only used the sendsms
command and was only searching in /usr/bin and /usr/local/bin.
This is more flexible now.
---
.werks/362 | 12 ++++++++++++
ChangeLog | 1 +
notifications/sms | 16 +++++++++-------
3 files changed, 22 insertions(+), 7 deletions(-)
diff --git a/.werks/362 b/.werks/362
new file mode 100644
index 0000000..c93f3b0
--- /dev/null
+++ b/.werks/362
@@ -0,0 +1,12 @@
+Title: sms: now searching PATH for sendsms and smssend commands
+Level: 1
+Component: notifications
+Class: feature
+State: unknown
+Version: 1.2.5i1
+Date: 1387207352
+Targetversion: future
+
+In previous versions the notification plugin only used the sendsms
+command and was only searching in /usr/bin and /usr/local/bin.
+This is more flexible now.
diff --git a/ChangeLog b/ChangeLog
index f4acf3e..a722b8a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -58,6 +58,7 @@
* 0361 FIX: The page linked by "new rule" can now be bookmarked again
Notifications:
+ * 0362 sms: now searching PATH for sendsms and smssend commands...
* 0108 FIX: Prevent service notification on host alerts...
* 0058 FIX: Fix email notifications containing non-ASCII characters in some situtations...
diff --git a/notifications/sms b/notifications/sms
index 3820672..7fdcf17 100755
--- a/notifications/sms
+++ b/notifications/sms
@@ -4,14 +4,16 @@
# Note: You have to add the side user to the sendsms group
# and restart the site
-import os
+import os, sys
-send_path = '/usr/bin/sendsms'
-if not os.path.exists(send_path):
- send_path = '/usr/local/bin/sendsms'
- if not os.path.exists(send_path):
- print "SMS Tools not found"
- os._exit(1)
+send_path = None
+for binary in [ 'sendsms', 'smssend' ]:
+ if os.system('which %s >/dev/null' % binary) == 0:
+ send_path = binary
+
+if not send_path:
+ sys.stderr.write('Error: SMS Tools binaries (sendsms or smssend) not found\n')
+ sys.exit(1)
max_len = 160
message = os.environ['NOTIFY_HOSTNAME'] + " "
Module: check_mk
Branch: master
Commit: ef6ecc8cd5ccd63c049ce3af622bdd594935ec5d
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=ef6ecc8cd5ccd6…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Dec 16 16:08:37 2013 +0100
FIX The page linked by "new rule" can now be bookmarked again
---
.werks/361 | 10 ++++++++++
ChangeLog | 1 +
web/htdocs/wato.py | 2 +-
3 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/.werks/361 b/.werks/361
new file mode 100644
index 0000000..9a90719
--- /dev/null
+++ b/.werks/361
@@ -0,0 +1,10 @@
+Title: The page linked by "new rule" can now be bookmarked again
+Level: 1
+Component: wato
+Class: fix
+State: unknown
+Version: 1.2.5i1
+Date: 1387206492
+Targetversion: future
+
+
diff --git a/ChangeLog b/ChangeLog
index ade0b7b..a8108f9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -53,6 +53,7 @@
* 0330 FIX: Improved performance of WATO slave push with a large user base...
* 0331 FIX: LDAP diagnostic LOG can now have the $OMD_SITE$ macro configured via WATO...
* 0332 FIX: Own host tag groups without topics resulted in two groups "Host tags" in the rule editor
+ * 0361 FIX: The page linked by "new rule" can now be bookmarked again
Notifications:
* 0108 FIX: Prevent service notification on host alerts...
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 8e2f0be..3c86012 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -10790,7 +10790,7 @@ def mode_rulesets(phase):
html.write('</div>')
def create_new_rule_form(rulespec, hostname = None, item = None, varname = None):
- html.begin_form("new_rule", add_transid = False, method = "POST")
+ html.begin_form("new_rule", add_transid = False)
html.write('<table>')
if hostname:
Module: check_mk
Branch: master
Commit: 2deaea52d637582a4e581bddda2f783773e3ed9a
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=2deaea52d63758…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Dec 16 15:45:29 2013 +0100
FIX multipath: Inventory handles non loaded kernel module now
The handling for not loaded multipath kernel module and not existing
multipath.conf was not working in all cases. This has been improved now.
---
.werks/360 | 11 +++++++++++
ChangeLog | 1 +
checks/multipath | 14 ++++++++++++--
3 files changed, 24 insertions(+), 2 deletions(-)
diff --git a/.werks/360 b/.werks/360
new file mode 100644
index 0000000..0226ffe
--- /dev/null
+++ b/.werks/360
@@ -0,0 +1,11 @@
+Title: multipath: Inventory handles non loaded kernel module now
+Level: 1
+Component: checks
+Class: fix
+State: unknown
+Version: 1.2.5i1
+Date: 1387205073
+Targetversion: future
+
+The handling for not loaded multipath kernel module and not existing
+multipath.conf was not working in all cases. This has been improved now.
diff --git a/ChangeLog b/ChangeLog
index 4606796..ade0b7b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -28,6 +28,7 @@
* 0355 FIX: heartbeat_crm: Now handling "Failed actions:" output in agent...
* 0357 FIX: megaraid_bbu: Fixed expected state checking...
* 0358 FIX: df: now ignores filesystems with a reported size of '-'...
+ * 0360 FIX: multipath: Inventory handles non loaded kernel module now...
Multisite:
* 0302 FIX: Fixed highlight of choosen elements in foldertee/views snapin in Chrome/IE
diff --git a/checks/multipath b/checks/multipath
index d3e73f4..6457f69 100644
--- a/checks/multipath
+++ b/checks/multipath
@@ -128,7 +128,14 @@
# \_ round-robin 0 [prio=-1][enabled]
# \_ 4:0:0:11 sdt 65:48 [active][undef]
-
+# And a completely new situation:
+# <<<multipath>>>
+# Nov 05 17:17:03 | DM multipath kernel driver not loaded
+# Nov 05 17:17:03 | /etc/multipath.conf does not exist, blacklisting all devices.
+# Nov 05 17:17:03 | A sample multipath.conf file is located at
+# Nov 05 17:17:03 | /usr/share/doc/device-mapper-multipath-0.4.9/multipath.conf
+# Nov 05 17:17:03 | You can run /sbin/mpathconf to create or modify /etc/multipath.conf
+# Nov 05 17:17:03 | DM multipath kernel driver not loaded
def parse_multipath_output(info, only_uuid = None):
# only_uuid --> look only for data of this uuid or alias
@@ -171,7 +178,10 @@ def parse_multipath_output(info, only_uuid = None):
l = " ".join(line)
# Skip output when multipath is not present
- if l.endswith('DM multipath kernel driver not loaded'):
+ if l.endswith('DM multipath kernel driver not loaded') \
+ or l.endswith('does not exist, blacklisting all devices.') \
+ or l.endswith('A sample multipath.conf file is located at') \
+ or l.endswith('multipath.conf'):
uuid = None
continue
Module: check_mk
Branch: master
Commit: 55b5ce495175393ab28b2a64ffd9e0ffb2394847
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=55b5ce49517539…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Mon Dec 16 15:31:59 2013 +0100
Updated bug entries #0969
---
.bugs/969 | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/.bugs/969 b/.bugs/969
index 10b6a7e..76547f5 100644
--- a/.bugs/969
+++ b/.bugs/969
@@ -1,12 +1,15 @@
Title: Logwatch in Windows Agent: Problem with EventId 0
Component: checks
-State: open
+Class: bug
+State: wontfix
Date: 2013-08-09 14:16:36
Targetversion: 1.2.3i6
-Class: bug
Ich überwache mit dem aktuellen Agent WinEventlogs und kann auf zwei
Maschinen einen Fehler beobachten wenn die EventID 0 ist. Die Severity
bleibt gleich aber der Text wird auf The Operation completed successfully
gesetzt. Das geschieht scheinbar durch den Agent selbst, da cmk -d bereits
die veränderten Werte anzeigt.
+
+2013-12-16 15:31:56: changed state open -> wontfix
+Die Angaben reichen leider nicht, um das Problem zu untersuchen.
Module: check_mk
Branch: master
Commit: aa0ff9887b1979c04217299dc59679e1535860af
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=aa0ff9887b1979…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Mon Dec 16 15:30:11 2013 +0100
Windows agent: fix code indentation
---
agents/windows/check_mk_agent.cc | 75 +++++++++++++++++++-------------------
1 file changed, 37 insertions(+), 38 deletions(-)
diff --git a/agents/windows/check_mk_agent.cc b/agents/windows/check_mk_agent.cc
index adeda0f..34cafea 100755
--- a/agents/windows/check_mk_agent.cc
+++ b/agents/windows/check_mk_agent.cc
@@ -1067,7 +1067,6 @@ bool output_eventlog_entry(SOCKET &out, char *dllpath, EVENTLOGRECORD *event, ch
dwFlags |= FORMAT_MESSAGE_FROM_HMODULE;
DWORD len = FormatMessageW(
- // DWORD len = FormatMessage(
dwFlags,
dll,
event->EventID,
@@ -1075,46 +1074,46 @@ bool output_eventlog_entry(SOCKET &out, char *dllpath, EVENTLOGRECORD *event, ch
wmsgbuffer,
// msgbuffer,
2048,
- (char **)strings);
+ (char **)strings
+ );
- if (dll)
- FreeLibrary(dll);
+ if (dll)
+ FreeLibrary(dll);
- if (len)
- {
- // convert message to UTF-8
- len = WideCharToMultiByte(CP_UTF8, 0, wmsgbuffer, -1, msgbuffer, sizeof(msgbuffer), NULL, NULL);
- }
+ if (len) {
+ // convert message to UTF-8
+ len = WideCharToMultiByte(CP_UTF8, 0, wmsgbuffer, -1, msgbuffer, sizeof(msgbuffer), NULL, NULL);
+ }
- if (len == 0) // message could not be converted
- {
- // if conversion was not successfull while trying to load a DLL, we return a
- // failure. Our parent function will then retry later without a DLL path.
- if (dllpath)
- return false;
-
- // if message cannot be converted, then at least output the text strings.
- // We render all messages one after the other into msgbuffer, separated
- // by spaces.
- memset(msgbuffer, 0, sizeof(msgbuffer)); // avoids problems with 0-termination
- char *w = msgbuffer;
- int sizeleft = sizeof(msgbuffer) - 1; // leave one byte for termination
- int n = 0;
- while (strings[n]) // string array is zero terminated
- {
- WCHAR *s = strings[n];
- DWORD len = WideCharToMultiByte(CP_UTF8, 0, s, -1, w, sizeleft, NULL, NULL);
- if (!len)
- break;
- sizeleft -= len;
- w += len;
- if (sizeleft <= 0)
- break;
- n++;
- if (strings[n])
- *w++ = ' ';
- }
- }
+ if (len == 0) // message could not be converted
+ {
+ // if conversion was not successfull while trying to load a DLL, we return a
+ // failure. Our parent function will then retry later without a DLL path.
+ if (dllpath)
+ return false;
+
+ // if message cannot be converted, then at least output the text strings.
+ // We render all messages one after the other into msgbuffer, separated
+ // by spaces.
+ memset(msgbuffer, 0, sizeof(msgbuffer)); // avoids problems with 0-termination
+ char *w = msgbuffer;
+ int sizeleft = sizeof(msgbuffer) - 1; // leave one byte for termination
+ int n = 0;
+ while (strings[n]) // string array is zero terminated
+ {
+ WCHAR *s = strings[n];
+ DWORD len = WideCharToMultiByte(CP_UTF8, 0, s, -1, w, sizeleft, NULL, NULL);
+ if (!len)
+ break;
+ sizeleft -= len;
+ w += len;
+ if (sizeleft <= 0)
+ break;
+ n++;
+ if (strings[n])
+ *w++ = ' ';
+ }
+ }
// replace newlines with spaces. check_mk expects one message each line.
char *w = msgbuffer;
Module: check_mk
Branch: master
Commit: 3e5322b46dcfd783e7ffe427e520f9ba4e67a759
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=3e5322b46dcfd7…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Dec 16 15:09:41 2013 +0100
FIX df: now ignores filesystems with a reported size of '-'
Previous versions of the check raised an exception because the '-'
could not be converted via int().
---
.werks/358 | 11 +++++++++++
ChangeLog | 1 +
checks/df | 3 +--
3 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/.werks/358 b/.werks/358
new file mode 100644
index 0000000..278eb0b
--- /dev/null
+++ b/.werks/358
@@ -0,0 +1,11 @@
+Title: df: now ignores filesystems with a reported size of '-'
+Level: 1
+Component: checks
+Class: fix
+State: unknown
+Version: 1.2.5i1
+Date: 1387202921
+Targetversion: future
+
+Previous versions of the check raised an exception because the '-'
+could not be converted via int().
diff --git a/ChangeLog b/ChangeLog
index 80ddcf8..a9d1b67 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -27,6 +27,7 @@
* 0334 FIX: cisco_fantray: Fixed error on Cisco devices which do not support this check...
* 0355 FIX: heartbeat_crm: Now handling "Failed actions:" output in agent...
* 0357 FIX: megaraid_bbu: Fixed expected state checking...
+ * 0358 FIX: df: now ignores filesystems with a reported size of '-'...
Multisite:
* 0302 FIX: Fixed highlight of choosen elements in foldertee/views snapin in Chrome/IE
diff --git a/checks/df b/checks/df
index 516cc4e..e67770c 100644
--- a/checks/df
+++ b/checks/df
@@ -37,8 +37,7 @@ def inventory_df(info):
if line[1] in inventory_df_exclude_fs:
continue # ignore this filesystem type
- size_kb = int(line[2])
- if size_kb == 0 or line[5] == '-':
+ if line[2] == '-' or int(line[2]) == 0 or line[5] == '-':
continue # exclude filesystems without size
mountpoint = " ".join(line[6:]).replace('\\', '/') # Windows \ is replaced with /