Module: check_mk
Branch: master
Commit: 08f8e95eb51be04bd91e3ebcf61301f501546e2d
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=08f8e95eb51be0…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Nov 25 09:26:43 2013 +0100
FIX Fixed bookmarking of absolute URLs or PNP/NagVis URLs in sidebar snapin
In previous versions, the URLs not pointing to multisite pages, bookmarked with
the sidebar snapin, could not be used, as they pointed to non existing URLs. This
was caused by th URL shortening algorithm used within the bookmark snapin.
---
.werks/285 | 10 ++++++++++
ChangeLog | 1 +
web/htdocs/sidebar.py | 41 ++++++++++++++++++++++++++++++++---------
3 files changed, 43 insertions(+), 9 deletions(-)
diff --git a/.werks/285 b/.werks/285
new file mode 100644
index 0000000..b854415
--- /dev/null
+++ b/.werks/285
@@ -0,0 +1,10 @@
+Title: Fixed bookmarking of absolute URLs or PNP/NagVis URLs in sidebar snapin
+Level: 1
+Component: multisite
+Version: 1.2.3i7
+Date: 1385367764
+Class: fix
+
+In previous versions, the URLs not pointing to multisite pages, bookmarked with
+the sidebar snapin, could not be used, as they pointed to non existing URLs. This
+was caused by th URL shortening algorithm used within the bookmark snapin.
diff --git a/ChangeLog b/ChangeLog
index 8a77f1c..2a31f2a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -45,6 +45,7 @@
* 0035 FIX: http[s] links are display again in the plugin output...
* 0006 FIX: Checkboxes for hosts/services were missing on modified views...
* 0284 FIX: Context help toggled on/off randomly...
+ * 0285 FIX: Fixed bookmarking of absolute URLs or PNP/NagVis URLs in sidebar snapin...
WATO:
* 0053 New rule for configuring the display_name of a service...
diff --git a/web/htdocs/sidebar.py b/web/htdocs/sidebar.py
index 151bb9e..3283123 100644
--- a/web/htdocs/sidebar.py
+++ b/web/htdocs/sidebar.py
@@ -25,7 +25,7 @@
# Boston, MA 02110-1301 USA.
import config, defaults, livestatus, views, pprint, os, copy, userdb
-import notify
+import notify, urlparse
from lib import *
# Constants to be used in snapins
@@ -562,16 +562,39 @@ def ajax_add_bookmark():
href = html.var("href")
if title and href:
bookmarks = load_bookmarks()
- # We try to remove http://hostname/some/path/check_mk from the
- # URI. That keeps the configuration files (bookmarks) portable.
- # Problem here: We have not access to our own URL, only to the
- # path part. The trick: we use the Referrer-field from our
- # request. That points to the sidebar.
referer = html.req.headers_in.get("Referer")
+
if referer:
- while '/' in referer and referer.split('/')[0] == href.split('/')[0]:
- referer = referer.split('/', 1)[1]
- href = href.split('/', 1)[1]
+ ref_p = urlparse.urlsplit(referer)
+ url_p = urlparse.urlsplit(href)
+
+ # If http/https or user, pw, host, port differ, don't try to shorten
+ # the URL to be linked. Simply use the full URI
+ if ref_p.scheme == url_p.scheme and ref_p.netloc == url_p.netloc:
+ # We try to remove http://hostname/some/path/check_mk from the
+ # URI. That keeps the configuration files (bookmarks) portable.
+ # Problem here: We have not access to our own URL, only to the
+ # path part. The trick: we use the Referrer-field from our
+ # request. That points to the sidebar.
+ referer = ref_p.path
+ href = url_p.path
+ if url_p.query:
+ href += '?' + url_p.query
+ removed = 0
+ while '/' in referer and referer.split('/')[0] == href.split('/')[0]:
+ referer = referer.split('/', 1)[1]
+ href = href.split('/', 1)[1]
+ removed += 1
+
+ if removed == 1:
+ # removed only the first "/". This should be an absolute path.
+ href = '/' + href
+ elif '/' in referer:
+ # there is at least one other directory layer in the path, make
+ # the link relative to the sidebar.py's topdir. e.g. for pnp
+ # links in OMD setups
+ href = '../' + href
+
bookmarks.append((title, href))
save_bookmarks(bookmarks)
render_bookmarks()
Module: check_mk
Branch: master
Commit: 843dd71342d39e0ca521de2e743820d2ed063356
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=843dd71342d39e…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Fri Nov 22 10:00:21 2013 +0100
FIX Fixed missing entries in log file and availability view
This problem occurred for example when you first visited the
global logfile and afterwards used the availability reporting.
This problem was due a bug in livestatus that affected the tables <tt>log</tt>
and <tt>statehist</tt>. Two consecutive logfile queries, each with different
logclasses, could lead to invalid/missing logfile entries.
---
.werks/233 | 2 +-
ChangeLog | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/.werks/233 b/.werks/233
index 8180fc9..7de204b 100644
--- a/.werks/233
+++ b/.werks/233
@@ -1,4 +1,4 @@
-Title: Fixed missing entries in log file or availability view
+Title: Fixed missing entries in log file and availability view
Level: 2
Component: livestatus
Version: 1.2.3i7
diff --git a/ChangeLog b/ChangeLog
index 511b9a3..0ed7a20 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -83,7 +83,7 @@
* 0067 livedump: new option to mark the mode at the beginning of the dump and documentation fixes...
* 0023 FIX: table statehist: code cleanup / minor performance improvements
* 0034 FIX: table statehist: no more missing entries if only one logfile exists
- * 0233 FIX: Fixed missing entries in log file or availability view...
+ * 0233 FIX: Fixed missing entries in log file and availability view...
1.2.3i6:
Module: check_mk
Branch: master
Commit: db2b645c8c080de0fb7213e8550095cba7760079
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=db2b645c8c080d…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Fri Nov 22 11:16:54 2013 +0100
fritz.conn fritz.config fritz.uptime fritz.wan_if fritz.link: New checks for monitoring Fritz!Box devices
This feature introduces a special agent, which uses the uPnP API of Fritz!Box
routers to retrieve several monitoring information, like the current connection
state, bandwith, update and several other things.
New checks are:
<table>
<tr><td class=tt>fritz.conn</td><td>Connection State / Info</td></tr>
<tr><td class=tt>fritz.config</td><td>Internet Connection related config.</td></tr>
<tr><td class=tt>fritz.uptime</td><td>Device Uptime</td></tr>
<tr><td class=tt>fritz.wan_if</td><td>Traffic of the WAN network interface</td></tr>
<tr><td class=tt>fritz.link</td><td>Network Link State / Info</td></tr>
</table>
---
.werks/47 | 2 +-
ChangeLog | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/.werks/47 b/.werks/47
index f41b6cd..5384c74 100644
--- a/.werks/47
+++ b/.werks/47
@@ -1,4 +1,4 @@
-Title: Add new collection of checks to monitor Fritz!Box devices
+Title: fritz.conn fritz.config fritz.uptime fritz.wan_if fritz.link: New checks for monitoring Fritz!Box devices
Level: 1
Component: checks
Version: 1.2.3i7
diff --git a/ChangeLog b/ChangeLog
index 1b77bf6..2b53347 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,7 +7,7 @@
* 0061 cisco_cpu: check now recognizes new object cpmCPUTotal5minRev...
* 0063 veeam_client: new check to monitor status of veeam clients with special agent plugin...
* 0064 veeam_jobs: new check to monitor the backup jobs of the veeam backup tool...
- * 0047 Add new collection of checks to monitor Fritz!Box devices...
+ * 0047 fritz.conn fritz.config fritz.uptime fritz.wan_if fritz.link: New checks for monitoring Fritz!Box devices...
* 0027 esx_vsphere_sensors: it is now possible override the state of sensors
* 0090 apc_ats_status: New Check for monitoring APC Automatic Transfer Switches
* 0080 Added new checks for Brocade NetIron MLX switching / routing devices...
Module: check_mk
Branch: master
Commit: 41e3b36aa2969889d719afe13a0d7a0d05feafff
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=41e3b36aa29698…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Fri Nov 22 15:18:30 2013 +0100
html.attrencode now tries to convert non - str/unicode values (e.g Exception messages) into a str
---
web/htdocs/htmllib.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/web/htdocs/htmllib.py b/web/htdocs/htmllib.py
index c3884a3..16f2c8c 100644
--- a/web/htdocs/htmllib.py
+++ b/web/htdocs/htmllib.py
@@ -1076,6 +1076,9 @@ class html:
def attrencode(self, value):
if type(value) == int:
return str(value)
+ elif type(value) not in [str, unicode]:
+ value = str(value)
+
new = ""
for c in value:
if c == '"':
Module: check_mk
Branch: master
Commit: 52a6fdd257456ef3bed6a62b9bbd085ba356bc5e
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=52a6fdd257456e…
Author: Bernd Stroessenreuther <bs(a)mathias-kettner.de>
Date: Fri Nov 22 15:04:58 2013 +0100
Added new checks for Brocade NetIron MLX switching / routing devices
Checked are by SNMP:
the status of Power supplies and Fans
the overall status of modules
memory usage and cpu utilization of NI-MLX modules
temperature measured by different temperature sensors
---
.werks/80 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.werks/80 b/.werks/80
index b1b5552..066eaca 100644
--- a/.werks/80
+++ b/.werks/80
@@ -5,7 +5,7 @@ Version: 1.2.3i7
Date: 1383827175
Class: feature
-It checks by SNMP
+Checked are by SNMP:
the status of Power supplies and Fans
the overall status of modules
memory usage and cpu utilization of NI-MLX modules
Module: check_mk
Branch: master
Commit: 64c2e5537614982dd87a67829e9ad800e8c99d11
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=64c2e553761498…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Nov 22 14:42:17 2013 +0100
Updated bug entries #1073
---
.bugs/1073 | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/.bugs/1073 b/.bugs/1073
index fb7d8e8..030992b 100644
--- a/.bugs/1073
+++ b/.bugs/1073
@@ -1,12 +1,15 @@
Title: Chrome: help switches on randomly
Component: multisite
-State: open
+Class: bug
+State: done
Date: 2013-10-15 23:42:57
Targetversion: 1.2.3i5
-Class: bug
The online help sometimes randomly switches on on Chrome on Windows.
Never seen this on Firefox. Seems like the help.mk in the user profile
correctly corresponds to the settings, so there it is no javascript problem?
This seems hard to reproduce. We can use Chrome for a while...
+
+2013-11-22 14:42:11: changed state open -> done
+It was caused by setting the option before having the user context.
examples to LDAP config help
Message-ID: <528f61c2.ZP6xgHBxSx6CZDFS%lm(a)mathias-kettner.de>
User-Agent: Heirloom mailx 12.4 7/29/08
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Module: check_mk
Branch: master
Commit: be1348cd0da84ae94edbfe1c217539845dbb1e66
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=be1348cd0da84a…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Nov 22 14:17:19 2013 +0100
ldap: added some more explainaition / examples to LDAP config help
---
web/plugins/wato/check_mk_configuration.py | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/web/plugins/wato/check_mk_configuration.py b/web/plugins/wato/check_mk_configuration.py
index 654d535..09ac8b9 100644
--- a/web/plugins/wato/check_mk_configuration.py
+++ b/web/plugins/wato/check_mk_configuration.py
@@ -658,13 +658,17 @@ register_configvar(group,
title = _("Search Filter"),
help = _("Using this option you can define an optional LDAP filter which is used during "
"LDAP searches. It can be used to only handle a subset of the users below the given "
- "base DN."),
+ "base DN.<br><br>Some common examples:<br><br> "
+ "All user objects in LDAP:<br> "
+ "<code>(&(objectclass=user)(objectcategory=person))</code><br> "
+ "Members of a group:<br> "
+ "<code>(&(objectclass=user)(objectcategory=person)(memberof=CN=cmk-users,OU=Groups,DC=corp,DC=de))</code><br>"),
size = 80,
default_value = lambda: userdb.ldap_filter('users', False),
attrencode = True,
)),
("filter_group", LDAPDistinguishedName(
- title = _("Filter Group"),
+ title = _("Filter Group (Only use in special situations)"),
help = _("Using this option you can define the DN of a group object which is used to filter the users. "
"Only members of this group will then be synchronized. This is a filter which can be "
"used to extend capabilities of the regular \"Search Filter\". Using the search filter "
@@ -673,7 +677,8 @@ register_configvar(group,
"directories. But some directories do not have such attributes because the memberships "
"are stored in the group objects as e.g. \"member\" attributes. You should use the "
"regular search filter whenever possible and only use this filter when it is really "
- "neccessary."),
+ "neccessary. Finally you can say, you should not use this option when using Active Directory. "
+ "This option is neccessary in OpenLDAP directories when you like to filter by group membership."),
size = 80,
)),
("user_id", TextAscii(