Module: check_mk
Branch: master
Commit: 807736b81b49fc45a7cd6df66de7e8383d12a47a
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=807736b81b49fc…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Wed Jan 8 10:46:28 2014 +0100
Implemented role permissions for dashboards
Access to dashboards can now be controlled via role permissions. By
default all roles are permitted to acces all dashboards (like in
previous versions). You can now change access to the dashboards per
role.
---
.werks/429 | 11 +++++++++++
ChangeLog | 1 +
web/htdocs/dashboard.py | 20 ++++++++++++++++----
web/plugins/sidebar/shipped.py | 2 +-
4 files changed, 29 insertions(+), 5 deletions(-)
diff --git a/.werks/429 b/.werks/429
new file mode 100644
index 0000000..a9baccb
--- /dev/null
+++ b/.werks/429
@@ -0,0 +1,11 @@
+Title: Implemented role permissions for dashboards
+Level: 2
+Component: multisite
+Version: 1.2.5i1
+Date: 1389174300
+Class: feature
+
+Access to dashboards can now be controlled via role permissions. By
+default all roles are permitted to acces all dashboards (like in
+previous versions). You can now change access to the dashboards per
+role.
diff --git a/ChangeLog b/ChangeLog
index af1d911..3b1bad0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -83,6 +83,7 @@
* 0390 Added an icon selector to the view editor...
* 0391 Added sorter / filter for host/service service levels...
* 0247 New mkp package for web applications: iNag / nagstatus / nagios status.dat...
+ * 0429 Implemented role permissions for dashboards...
* 0302 FIX: Fixed highlight of choosen elements in foldertee/views snapin in Chrome/IE
* 0239 FIX: Fixed incorrect html formatting when displaying host or service comments...
* 0307 FIX: Increased performance of multisite GUI with a large userbase...
diff --git a/web/htdocs/dashboard.py b/web/htdocs/dashboard.py
index 9a8670e..34e1c77 100644
--- a/web/htdocs/dashboard.py
+++ b/web/htdocs/dashboard.py
@@ -61,10 +61,6 @@ def load_plugins():
if loaded_with_language == current_language:
return
- # Permissions are currently not being defined. That will be the
- # case as soon as dashboards become editable.
-
-
# Load plugins for dashboards. Currently these files
# just may add custom dashboards by adding to builtin_dashboards.
load_web_plugins("dashboard", globals())
@@ -80,6 +76,20 @@ def load_plugins():
global dashboards
dashboards = builtin_dashboards
+ # Declare permissions for all dashboards
+ config.declare_permission_section("dashboard", _("Dashboards"))
+ for name, dashboard in dashboards.items():
+ config.declare_permission("dashboard.%s" % name,
+ dashboard["title"],
+ dashboard.get("description", ''),
+ config.builtin_role_ids)
+
+def permitted_dashboards():
+ return [ (name, dashboard) for name, dashboard
+ in dashboards.items()
+ if config.may("dashboard.%s" % name)
+ ]
+
# HTML page handler for generating the (a) dashboard. The name
# of the dashboard to render is given in the HTML variable 'name'.
# This defaults to "main".
@@ -87,6 +97,8 @@ def page_dashboard():
name = html.var("name", "main")
if name not in dashboards:
raise MKGeneralException("No such dashboard: '<b>%s</b>'" % name)
+ if not config.may("dashboard.%s" % name):
+ raise MKAuthException(_("You are not allowed to access this dashboard."))
render_dashboard(name)
diff --git a/web/plugins/sidebar/shipped.py b/web/plugins/sidebar/shipped.py
index 89009e7..f7b047e 100644
--- a/web/plugins/sidebar/shipped.py
+++ b/web/plugins/sidebar/shipped.py
@@ -77,7 +77,7 @@ def views_by_topic():
# Add all the dashboards to the views list
s += [ (_('Dashboards'), d['title'] and d['title'] or d_name, d_name)
for d_name, d
- in dashboard.dashboards.items()
+ in dashboard.permitted_dashboards()
]
s.sort()
Module: check_mk
Branch: master
Commit: a17d61a1fd29c002865597b13934c8a966d7a2f4
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=a17d61a1fd29c0…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Jan 8 00:47:53 2014 +0100
Fixed some further help texts and descriptions
---
mkeventd/web/plugins/wato/mkeventd.py | 2 +-
web/htdocs/wato.py | 10 +++++-----
web/plugins/sidebar/wato.py | 2 +-
web/plugins/views/availability.py | 2 +-
web/plugins/views/filters.py | 2 +-
web/plugins/wato/active_checks.py | 2 +-
web/plugins/wato/check_mk_configuration.py | 4 ++--
web/plugins/wato/check_parameters.py | 4 ++--
web/plugins/wato/datasource_programs.py | 2 +-
9 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/mkeventd/web/plugins/wato/mkeventd.py b/mkeventd/web/plugins/wato/mkeventd.py
index 579731b..2038676 100644
--- a/mkeventd/web/plugins/wato/mkeventd.py
+++ b/mkeventd/web/plugins/wato/mkeventd.py
@@ -1385,7 +1385,7 @@ if mkeventd_enabled:
config.declare_permission_section("mkeventd", _("Event Console"))
config.declare_permission("mkeventd.config",
- _("Configuration of event console "),
+ _("Configuration of Event Console "),
_("This permission allows to configure the global settings "
"of the event console."),
["admin"])
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 2238712..28fadd3 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -6072,7 +6072,7 @@ def mode_ldap_config(phase):
new_value = valuespec.from_html_vars(varname)
valuespec.validate_value(new_value, varname)
if current_settings.get(varname) != new_value:
- msg = _("Changed ldap configuration variable %s to %s.") \
+ msg = _("Changed LDAP configuration variable %s to %s.") \
% (varname, valuespec.value_to_text(new_value))
log_pending(SYNC, None, "edit-configvar", msg)
current_settings[varname] = new_value
@@ -6207,7 +6207,7 @@ def mode_ldap_config(phase):
return True, _('Found all %d groups.') % num
tests = [
- (_('Connect'), test_connect),
+ (_('Connection'), test_connect),
(_('User Base-DN'), test_user_base_dn),
(_('Count Users'), test_user_count),
(_('Group Base-DN'), test_group_base_dn),
@@ -7555,7 +7555,7 @@ def mode_edit_site_globals(phase):
c = wato_confirm(
_("Removing site-specific configuration variable"),
_("Do you really want to remove the configuration variable <b>%s</b> "
- "of the specifi configuration of this site and that way use the global value "
+ "of the specific configuration of this site and that way use the global value "
"of <b><tt>%s</tt></b>?") %
(varname, valuespec.value_to_text(def_value)))
else:
@@ -11965,7 +11965,7 @@ def mode_edit_rule(phase, new = False):
return (back_mode,
(new and _("Created new rule in ruleset '%s' in folder %s")
- or _("Editor rule in ruleset '%s' in folder %s")) %
+ or _("Edited rule in ruleset '%s' in folder %s")) %
(rulespec["title"], new_rule_folder["title"]))
if rulespec.get("help"):
@@ -13278,7 +13278,7 @@ def mode_bi_rules(phase):
elif html.var("_del_aggr"):
nr = int(html.var("_del_aggr"))
c = wato_confirm(_("Confirm aggregation deletion"),
- _("Do you really want to delete the aggregation number <b>%s</b>") % (nr+1))
+ _("Do you really want to delete the aggregation number <b>%s</b>?") % (nr+1))
if c:
del aggregations[nr]
log_audit(None, "bi-delete-aggregation", _("Deleted BI aggregation number %d") % (nr+1))
diff --git a/web/plugins/sidebar/wato.py b/web/plugins/sidebar/wato.py
index 539eed3..418af3f 100644
--- a/web/plugins/sidebar/wato.py
+++ b/web/plugins/sidebar/wato.py
@@ -246,7 +246,7 @@ def render_wato_foldertree():
render_tree_folder(user_folders.values()[0], 'wato_tree_click')
sidebar_snapins['wato_foldertree'] = {
- 'title' : _('Foldertree (standalone)'),
+ 'title' : _('Tree of Folders'),
'description' : _('This snapin shows the folders defined in WATO. It can be used to open views filtered by the WATO folder. It works standalone, without interaction with any other snapin.'),
'render' : render_wato_foldertree,
'allowed' : [ 'admin', 'user', 'guest' ],
diff --git a/web/plugins/views/availability.py b/web/plugins/views/availability.py
index 8db618f..1176517 100644
--- a/web/plugins/views/availability.py
+++ b/web/plugins/views/availability.py
@@ -1719,7 +1719,7 @@ def handle_delete_annotations():
if not annotation:
return
- if not html.confirm(_("Are you sure that you want to delete the annotation '%s'" % annotation["text"])):
+ if not html.confirm(_("Are you sure that you want to delete the annotation '%s'?" % annotation["text"])):
return
delete_annotation(annotations, site_host_svc, fromtime, untiltime)
diff --git a/web/plugins/views/filters.py b/web/plugins/views/filters.py
index 00d64be..36663ee 100644
--- a/web/plugins/views/filters.py
+++ b/web/plugins/views/filters.py
@@ -71,7 +71,7 @@ declare_filter(201, FilterText("service", _("Service (exact match)"),
declare_filter(202, FilterText("service_display_name", _("Service alternative display name"), "service", "service_display_name", "service_display_name", "~~"),
_("Alternative display name of the service, regex match"))
-declare_filter(101, FilterText("hostgroupnameregex", _("Hostgroup)"), "hostgroup", "hostgroup_name", "hostgroup_name", "~~"),
+declare_filter(101, FilterText("hostgroupnameregex", _("Hostgroup"), "hostgroup", "hostgroup_name", "hostgroup_name", "~~"),
_("Search field allowing regular expressions and partial matches on the names of hostgroups"))
declare_filter(101, FilterText("servicegroupnameregex", _("Servicegroup"), "servicegroup", "servicegroup_name", "servicegroup_name", "~~"),
diff --git a/web/plugins/wato/active_checks.py b/web/plugins/wato/active_checks.py
index dd13411..9f61da3 100644
--- a/web/plugins/wato/active_checks.py
+++ b/web/plugins/wato/active_checks.py
@@ -182,7 +182,7 @@ register_rule(group,
TextAscii(
title = _("Expected Address"),
allow_empty = False,
- help = _("Optional IP-ADDRESS you expect the DNS server to return. HOST"
+ help = _("Optional IP-Address you expect the DNS server to return. The host "
"must end with a dot (.) " )),
),
( "expected_authority",
diff --git a/web/plugins/wato/check_mk_configuration.py b/web/plugins/wato/check_mk_configuration.py
index 84f08f6..e0bed14 100644
--- a/web/plugins/wato/check_mk_configuration.py
+++ b/web/plugins/wato/check_mk_configuration.py
@@ -646,8 +646,8 @@ register_configvar(group,
)),
("scope", DropdownChoice(
title = _("Search Scope"),
- help = _("Scope to be used in LDAP searches. In most cases <tt>Search whole subtree below "
- "the base DN</tt> is the best choice. "
+ help = _("Scope to be used in LDAP searches. In most cases <i>Search whole subtree below "
+ "the base DN</i> is the best choice. "
"It searches for matching objects recursively."),
choices = [
("sub", _("Search whole subtree below the base DN")),
diff --git a/web/plugins/wato/check_parameters.py b/web/plugins/wato/check_parameters.py
index 4fe0971..bf522e2 100644
--- a/web/plugins/wato/check_parameters.py
+++ b/web/plugins/wato/check_parameters.py
@@ -3447,7 +3447,7 @@ register_check_parameters(
elements = [
("lower",
Tuple(
- help = _("Lower levels for the FAN speed of a hardware device"),
+ help = _("Lower levels for the fan speed of a hardware device"),
title = _("Lower levels"),
elements = [
Integer(title = _("warning if below"), unit = u"rpm"),
@@ -3761,7 +3761,7 @@ register_check_parameters(
),
("level_high",
Tuple(
- title = _("Higher levels"),
+ title = _("Upper levels"),
elements = [
Integer(title = _( "Warning if above"), unit=_("l/s")),
Integer(title = _( "Critical if above"), unit=_("l/s"))
diff --git a/web/plugins/wato/datasource_programs.py b/web/plugins/wato/datasource_programs.py
index 301932d..c906850 100644
--- a/web/plugins/wato/datasource_programs.py
+++ b/web/plugins/wato/datasource_programs.py
@@ -152,7 +152,7 @@ register_rule(group,
Integer( title = _("Port Number"), default_value=8161 ),
ListChoice(
choices = [
- ("piggybag", _("Run in piggybag mode")),
+ ("piggybag", _("Run in piggyback mode")),
],
allow_empty = True
)
Module: check_mk
Branch: master
Commit: e4592af3df3d6e6877efccb3405fca13834a2a3c
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=e4592af3df3d6e…
Author: Bernd Stroessenreuther <bs(a)mathias-kettner.de>
Date: Tue Jan 7 20:25:32 2014 +0100
brocade_mlx: enhancing checks (BR-MLX modules, more OK states)
CPU and Memory Checks now look on BR-MLX modules too
Status "Blocked for full height card" is an OK state now
---
.werks/321 | 9 +++++++++
ChangeLog | 1 +
checkman/brocade_mlx.module_cpu | 4 ++--
checkman/brocade_mlx.module_mem | 4 ++--
checkman/brocade_mlx.module_status | 2 +-
checks/brocade_mlx | 10 +++++-----
6 files changed, 20 insertions(+), 10 deletions(-)
diff --git a/.werks/321 b/.werks/321
new file mode 100644
index 0000000..e6f13fb
--- /dev/null
+++ b/.werks/321
@@ -0,0 +1,9 @@
+Title: brocade_mlx: enhancing checks (BR-MLX modules, more OK states)
+Level: 2
+Component: checks
+Version: 1.2.5i1
+Date: 1389122496
+Class: feature
+
+CPU and Memory Checks now look on BR-MLX modules too
+Status "Blocked for full height card" is an OK state now
diff --git a/ChangeLog b/ChangeLog
index 851e048..048d07c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -31,6 +31,7 @@
* 0318 hitachi_hnas_fan: New check for fans in Hitachi HNAS systems
* 0319 hitachi_hnas_psu, hitachi_hnas_psu: New checks for Hitachi HNAS storage systems
* 0320 hitachi_hnas_fpga: new check for Hitachi HNAS storage systems
+ * 0321 brocade_mlx: enhancing checks (BR-MLX modules, more OK states)...
* 0103 FIX: services: Fixed bug with service inventory defined in main.mk...
* 0299 FIX: borcade_mlx_fan: Prettified output, handling "other" state now
* 0300 FIX: cisco_fru_power: Trying not to inventorize not plugged in FRUs...
diff --git a/checkman/brocade_mlx.module_cpu b/checkman/brocade_mlx.module_cpu
index 0431db2..876f9c3 100644
--- a/checkman/brocade_mlx.module_cpu
+++ b/checkman/brocade_mlx.module_cpu
@@ -1,10 +1,10 @@
-title: Brocade NetIron MLX devices: NI-MLX Module CPU Utilization
+title: Brocade NetIron MLX devices: NI-MLX or BR-MLX Module CPU Utilization
agents: snmp
catalog: hw/network/brocade
license: GPL
distribution: check_mk
description:
- Checks the Module CPU Utilization of a NI-MLX module in Brocade
+ Checks the Module CPU Utilization of a NI-MLX or BR-MLX module in Brocade
NetIron MLX switching / routing devices.
{WARN} or {CRIT} is returned, if the usage in the last 60 sec was above
diff --git a/checkman/brocade_mlx.module_mem b/checkman/brocade_mlx.module_mem
index 8135d89..e3d3974 100644
--- a/checkman/brocade_mlx.module_mem
+++ b/checkman/brocade_mlx.module_mem
@@ -1,10 +1,10 @@
-title: Brocade NetIron MLX devices: NI-MLX Module Memory (RAM usage)
+title: Brocade NetIron MLX devices: NI-MLX or BR-MLX Module Memory (RAM usage)
agents: snmp
catalog: hw/network/brocade
license: GPL
distribution: check_mk
description:
- Checks the Module Memory (RAM usage) of a NI-MLX module in Brocade
+ Checks the Module Memory (RAM usage) of a NI-MLX or BR-MLX module in Brocade
NetIron MLX switching / routing devices.
{WARN} or {CRIT} is returned, if the usage is above given thresholds.
diff --git a/checkman/brocade_mlx.module_status b/checkman/brocade_mlx.module_status
index 6109159..c27da0a 100644
--- a/checkman/brocade_mlx.module_status
+++ b/checkman/brocade_mlx.module_status
@@ -7,7 +7,7 @@ description:
Checks the overall status of modules in Brocade NetIron MLX
switching / routing devices.
- Returns {OK} on status 10 (running).
+ Returns {OK} on status 10 (running) and 11 (Blocked for full height card).
Returns {WARN} on status 0 (empty), 2 (going down) and 9 (coming up).
Returns {CRIT} on status 3 (rejected) and 4 (bad).
Returns {UNKN} on every other status.
diff --git a/checks/brocade_mlx b/checks/brocade_mlx
index cd32dd1..c8eb27d 100644
--- a/checks/brocade_mlx
+++ b/checks/brocade_mlx
@@ -32,7 +32,7 @@ brocade_mlx_states = {
8: (1, "Configured / Stacking"),
9: (1, "In power-up cycle"),
10: (0, "Running"),
- 11: (1, "Blocked for full height card"),
+ 11: (0, "Blocked for full height card"),
}
brocade_mlx_info = [
@@ -103,8 +103,8 @@ def inventory_brocade_mlx_module_mem(info):
inventory = []
for module_id, module_descr, module_state, mem_total, mem_avail in info[0]:
# do not inventorize modules reported as empty
- # and: monitor memory only on NI-MLX modules
- if module_state != "0" and module_descr.startswith("NI-MLX"):
+ # and: monitor cpu only on NI-MLX and BR-MLX modules
+ if module_state != "0" and ( module_descr.startswith("NI-MLX") or module_descr.startswith("BR-MLX") ):
inventory.append( (brocade_mlx_combine_item(module_id, module_descr), "brocade_mlx_mem_default_levels") )
return inventory
@@ -171,8 +171,8 @@ def inventory_brocade_mlx_module_cpu(info):
inventory = []
for module_id, module_descr, module_state, mem_total, mem_avail in info[0]:
# do not inventorize modules reported as empty
- # and: monitor cpu only on NI-MLX modules
- if module_state != "0" and module_descr.startswith("NI-MLX"):
+ # and: monitor cpu only on NI-MLX and BR-MLX modules
+ if module_state != "0" and ( module_descr.startswith("NI-MLX") or module_descr.startswith("BR-MLX") ):
inventory.append( (brocade_mlx_combine_item(module_id, module_descr), "brocade_mlx_cpu_default_levels") )
return inventory
Module: check_mk
Branch: master
Commit: c8c70bb64196f9307ddbf6ba63a2635e461e53c9
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=c8c70bb64196f9…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Jan 7 17:12:41 2014 +0100
Fixed some typos in help texts
---
web/plugins/wato/active_checks.py | 2 +-
web/plugins/wato/check_mk_configuration.py | 6 +++---
web/plugins/wato/datasource_programs.py | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/web/plugins/wato/active_checks.py b/web/plugins/wato/active_checks.py
index 5c43695..dd13411 100644
--- a/web/plugins/wato/active_checks.py
+++ b/web/plugins/wato/active_checks.py
@@ -75,7 +75,7 @@ register_rule(group,
"active_checks:icmp",
Dictionary(
title = _("Check hosts with PING (ICMP Echo Request)"),
- help = _("This ruleset allows you to configure explizit PING monitoring of hosts. "
+ help = _("This ruleset allows you to configure explicit PING monitoring of hosts. "
"Usually a PING is being used as a host check, so this is not neccessary. "
"There are some situations, however, where this can be useful. One of them "
"is when using the Check_MK Micro Core with SMART Ping and you want to "
diff --git a/web/plugins/wato/check_mk_configuration.py b/web/plugins/wato/check_mk_configuration.py
index a39398d..84f08f6 100644
--- a/web/plugins/wato/check_mk_configuration.py
+++ b/web/plugins/wato/check_mk_configuration.py
@@ -236,7 +236,7 @@ register_configvar(group,
label = _("Show WATO icon"),
help = _("When enabled a rule editor icon is displayed for each "
"service in the multisite views. It is only displayed if the user "
- "does have the permission to edit rules"),
+ "does have the permission to edit rules."),
default_value = False),
domain = "multisite")
@@ -307,8 +307,8 @@ register_configvar(group,
title = _("Adhoc downtime"),
label = _("Enable adhoc downtime"),
help = _("This setting allows to set an adhoc downtime comment and its duration. "
- "When enabled a new button <tt>Adhoc downtime for xx minutes</tt> will "
- "be available in the command form"),
+ "When enabled a new button <i>Adhoc downtime for __ minutes</i> will "
+ "be available in the command form."),
),
domain = "multisite",
)
diff --git a/web/plugins/wato/datasource_programs.py b/web/plugins/wato/datasource_programs.py
index 101af05..301932d 100644
--- a/web/plugins/wato/datasource_programs.py
+++ b/web/plugins/wato/datasource_programs.py
@@ -176,7 +176,7 @@ register_rule(group,
Dictionary(
title = _("Check state of Fritz!Box Devices"),
help = _("This rule selects the Fritz!Box agent, which uses UPNP to gather information "
- "about configuration and connection status information "),
+ "about configuration and connection status information."),
elements = [
( "timeout",
Integer(
Module: check_mk
Branch: master
Commit: 4b1fb2a353723b623c8c5141f2c4314ba351a0ac
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=4b1fb2a353723b…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Jan 7 15:59:27 2014 +0100
Changed user profiles (e.g. pw changes) are now replicated in distributed setups
When a user changed its password or its user profile attributes in previous versions, these
changes were only applied on the local (central) site in a distributed WATO setup. These
changes were only replicated to the slave sites when an administrator started replicating
other things to the slave sites. This has been changed now. When a user changes the profile
in a distributed setup, a sync dialog is opened and the sync of this user profile is
started for each slave site.
---
.werks/428 | 13 +++++++++++++
ChangeLog | 1 +
2 files changed, 14 insertions(+)
diff --git a/.werks/428 b/.werks/428
new file mode 100644
index 0000000..540c907
--- /dev/null
+++ b/.werks/428
@@ -0,0 +1,13 @@
+Title: Changed user profiles (e.g. pw changes) are now replicated in distributed setups
+Level: 2
+Component: wato
+Version: 1.2.5i1
+Date: 1389106579
+Class: feature
+
+When a user changed its password or its user profile attributes in previous versions, these
+changes were only applied on the local (central) site in a distributed WATO setup. These
+changes were only replicated to the slave sites when an administrator started replicating
+other things to the slave sites. This has been changed now. When a user changes the profile
+in a distributed setup, a sync dialog is opened and the sync of this user profile is
+started for each slave site.
diff --git a/ChangeLog b/ChangeLog
index 6371a30..39becd2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -111,6 +111,7 @@
* 0382 Active HTTP check now supports multiline regexp matching...
* 0112 Explicit mapping of clustered services can now be done with WATO...
* 0437 Convert WATO rule for debug_log into simple Checkbox...
+ * 0428 Changed user profiles (e.g. pw changes) are now replicated in distributed setups...
* 0057 FIX: Fix exception in WATO host editor on custom tag without topic...
* 0241 FIX: Improved sorting of WATO folders in dropdown menu...
* 0019 FIX: Fixed wording in WATO rule for MSSQL check
Module: check_mk
Branch: master
Commit: 68ed30a23ffabb8a22a87bf3145af0dd4ae8daec
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=68ed30a23ffabb…
Author: Bastian Kuhn <bk(a)mathias-kettner.de>
Date: Tue Jan 7 11:10:04 2014 +0100
Updated bug entries #0839
---
.bugs/839 | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/.bugs/839 b/.bugs/839
new file mode 100644
index 0000000..a926bd0
--- /dev/null
+++ b/.bugs/839
@@ -0,0 +1,14 @@
+Title: printer suply levels for ricoh
+Component: checks
+State: open
+Date: 2014-01-07 11:08:41
+Targetversion: future
+Class: bug
+
+Prinzipiell funktioniert der Check check_mk-printer_supply_ricoh gut allerdings haben wir festgestellt, dass er die Patronen verkehrt auswertet.
+
+Sprich wo 80% die Patrone voll ist erreicht die Auswertung 20% im Monitoring System und geht auf Warnung.
+
+Sprich nach Tausch ist der Drucker sofort auf kritisch und beim leer werden auf 100% voll.
+
+
fixed outdated systemtime of check_mk agent
Message-ID: <52cbccf9.CLG4VlK2IG3FWLAD%ab(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: 5fdf551fece051069d5bc696a190469c285af394
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5fdf551fece051…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Tue Jan 7 10:45:36 2014 +0100
FIX agent_vsphere / check_mk agent: fixed outdated systemtime of check_mk agent
The systemtime of the check_mk agent was incorrect most of the time whenever the
agent_vsphere was used together with the classic agent.
The reason was that the agent_vsphere program was called after the check_mk agent
- its execution took several seconds - thus leading to an outdated systemtime of the standard agent.
---
.werks/251 | 13 +++++++++++++
ChangeLog | 1 +
agents/special/agent_vsphere | 9 +++++----
agents/special/agent_vsphere.pysphere | 17 +++++++++++------
4 files changed, 30 insertions(+), 10 deletions(-)
diff --git a/.werks/251 b/.werks/251
new file mode 100644
index 0000000..c0d489a
--- /dev/null
+++ b/.werks/251
@@ -0,0 +1,13 @@
+Title: agent_vsphere / check_mk agent: fixed outdated systemtime of check_mk agent
+Level: 1
+Component: checks
+Class: fix
+State: unknown
+Version: 1.2.5i1
+Date: 1389087583
+Targetversion: future
+
+The systemtime of the check_mk agent was incorrect most of the time whenever the
+agent_vsphere was used together with the classic agent.
+The reason was that the agent_vsphere program was called after the check_mk agent
+- its execution took several seconds - thus leading to an outdated systemtime of the standard agent.
diff --git a/ChangeLog b/ChangeLog
index 6371a30..3ea6478 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -75,6 +75,7 @@
* 0397 FIX: mrpe: tolerate performance variable names with spaces...
* 0399 FIX: check_ftp: cleanup configuration via WATO, remove Hostname field...
* 0435 FIX: esx_vsphere_sensors: Fix garbled output in case of placeholder VMs...
+ * 0251 FIX: agent_vsphere / check_mk agent: fixed outdated systemtime of check_mk agent...
Multisite:
* 0371 Added log class filter to hostsvcevents view
diff --git a/agents/special/agent_vsphere b/agents/special/agent_vsphere
index f65eae0..b1ddcea 100755
--- a/agents/special/agent_vsphere
+++ b/agents/special/agent_vsphere
@@ -278,10 +278,6 @@ def get_agent_info_tcp(hostname):
raise
return output
-if opt_agent:
- sys.stdout.write(get_agent_info_tcp(host_address))
- sys.stdout.flush()
- error_exit = 0
results = {}
@@ -592,6 +588,11 @@ if not error:
raise
error = "Error while processing received data"
+if opt_agent:
+ sys.stdout.write(get_agent_info_tcp(host_address))
+ sys.stdout.flush()
+ error_exit = 0
+
if tracefile:
tracefile.close()
diff --git a/agents/special/agent_vsphere.pysphere b/agents/special/agent_vsphere.pysphere
index 68284f8..f5487dd 100755
--- a/agents/special/agent_vsphere.pysphere
+++ b/agents/special/agent_vsphere.pysphere
@@ -183,16 +183,16 @@ def get_agent_info_tcp(hostname):
return output
error_exit = 1
-if opt_agent:
- sys.stdout.write(get_agent_info_tcp(host_address))
- sys.stdout.flush()
- error_exit = 0 # do not fail if vSphere fails
-
try:
from pysphere import VIServer, VIProperty, MORTypes
from pysphere.resources import VimService_services as VI
-except:
+except:
+ # Get check_mk agent output even if pysphere is missing
+ if opt_agent:
+ sys.stdout.write(get_agent_info_tcp(host_address))
+ sys.stdout.flush()
+ error_exit = 0 # do not fail if vSphere fails
sys.stderr.write("pysphere API not found. Please install and try again.\n")
sys.exit(error_exit)
@@ -770,5 +770,10 @@ for entry in object_collection:
print "\t".join(entry)
host.disconnect()
+# Get check_mk agent output
+if opt_agent:
+ sys.stdout.write(get_agent_info_tcp(host_address))
+ sys.stdout.flush()
+
if g_profile:
output_profile()
Module: check_mk
Branch: master
Commit: 5ea6e6bf3e9cd7ff60c42aeed2bc7f5173d7ef85
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5ea6e6bf3e9cd7…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Jan 7 10:36:13 2014 +0100
Fix some typos in help texts
---
web/plugins/wato/check_parameters.py | 11 ++++++-----
web/plugins/wato/datasource_programs.py | 2 +-
2 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/web/plugins/wato/check_parameters.py b/web/plugins/wato/check_parameters.py
index fd44ab4..4fe0971 100644
--- a/web/plugins/wato/check_parameters.py
+++ b/web/plugins/wato/check_parameters.py
@@ -401,8 +401,8 @@ register_rule(group + '/' + subgroup_inventory,
)),
('handle_count', Tuple(
title = _('Handle Count (Windows only)'),
- help = _("The number of object handles in the process's object table. This includes open handles to "
- "threads, files and other resources like registry keys"),
+ help = _("The number of object handles in the processes object table. This includes open handles to "
+ "threads, files and other resources like registry keys."),
elements = [
Integer(
title = _("Warning above"),
@@ -1987,9 +1987,10 @@ register_check_parameters(
register_check_parameters(
subgroup_os,
"memory_multiitem",
- _("Main memory usage of Devices with Modules"),
+ _("Main memory usage of devices with modules"),
Dictionary(
- help = _("The memory levels for the sub-module of this host, e.g. pluggable cards"),
+ help = _("The memory levels for one specific module of this host. This is relevant for hosts that have "
+ "several distinct memory areas, e.g. pluggable cards"),
elements = [
("levels", Alternative(
title = _("Memory levels"),
@@ -4441,7 +4442,7 @@ register_check_parameters(
('handle_count', Tuple(
title = _('Handle Count (Windows only)'),
help = _("The number of object handles in the process's object table. This includes open handles to "
- "threads, files and other resources like registry keys"),
+ "threads, files and other resources like registry keys."),
elements = [
Integer(
title = _("Warning above"),
diff --git a/web/plugins/wato/datasource_programs.py b/web/plugins/wato/datasource_programs.py
index 446c6dd..a23d831 100644
--- a/web/plugins/wato/datasource_programs.py
+++ b/web/plugins/wato/datasource_programs.py
@@ -181,7 +181,7 @@ register_rule(group,
( "timeout",
Integer(
title = _("Connection timeout"),
- help = _("The network timeout in seconds when communicating via UPNP."
+ help = _("The network timeout in seconds when communicating via UPNP. "
"The default is 10 seconds. Please note that this "
"is not a total timeout, instead it is applied to each API call."),
default_value = 10,