Module: check_mk
Branch: master
Commit: be3c9c48f7012a794bbec1d7b7c707122446bf8b
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=be3c9c48f7012a…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu Apr 23 09:51:44 2015 +0200
#2223 Allow cancelling actions to be omitted of the cancelled event is not (yet) open
If you have an Event Console rule that uses delaying or counting at the
same time as cancelling, and if this rule furthermore defines actions when
cancelling, then you can have these actions only be executed if the event
has made it in to the <tt>open</tt> phase. The default is still the old
behaviour: that cancelling actions are also executed when the event is still
being delayed or in phase <tt>counting</tt>
---
.werks/2223 | 14 ++++++++++++++
ChangeLog | 1 +
mkeventd/bin/mkeventd | 11 ++++++++---
mkeventd/web/plugins/wato/mkeventd.py | 12 +++++++++++-
4 files changed, 34 insertions(+), 4 deletions(-)
diff --git a/.werks/2223 b/.werks/2223
new file mode 100644
index 0000000..ad178cb
--- /dev/null
+++ b/.werks/2223
@@ -0,0 +1,14 @@
+Title: Allow cancelling actions to be omitted of the cancelled event is not (yet) open
+Level: 1
+Component: ec
+Compatible: compat
+Version: 1.2.7i1
+Date: 1429775384
+Class: feature
+
+If you have an Event Console rule that uses delaying or counting at the
+same time as cancelling, and if this rule furthermore defines actions when
+cancelling, then you can have these actions only be executed if the event
+has made it in to the <tt>open</tt> phase. The default is still the old
+behaviour: that cancelling actions are also executed when the event is still
+being delayed or in phase <tt>counting</tt>
diff --git a/ChangeLog b/ChangeLog
index e1c2c29..e69a20c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -501,6 +501,7 @@
* 1878 SEC: Fixed possible shell injection when filtering the EC archive...
* 2099 Allow replication of Event Console rule and settings...
* 2107 mkeventd: can now handle syslog format of Sophos firewalls
+ * 2223 Allow cancelling actions to be omitted of the cancelled event is not (yet) open...
* 1839 FIX: Fix exception when notifying EC alert into monitoring for traps (because PID is missing)
* 1813 FIX: Fixed bug in event console rule editor when no contact groups configured
* 1974 FIX: Event console views were randomly ignoring host filters...
diff --git a/mkeventd/bin/mkeventd b/mkeventd/bin/mkeventd
index 8846616..3363138 100755
--- a/mkeventd/bin/mkeventd
+++ b/mkeventd/bin/mkeventd
@@ -2925,6 +2925,7 @@ class EventStatus():
# Fill a few fields of the cancelled event with data from
# the cancelling event so that action scripts have useful
# values and the logfile entry if more relevant.
+ previous_phase = event["phase"]
event["phase"] = "closed"
event["state"] = 0 # OK
event["text"] = new_event["text"]
@@ -2933,9 +2934,13 @@ class EventStatus():
event["priority"] = new_event["priority"]
log_event_history(event, "CANCELLED")
actions = rule.get("cancel_actions", [])
- # TODO: Execute the cancelling actions only, if the event
- # was open. Do not do this e.g. on delayed or counting.
- do_event_actions(actions, event, is_cancelling = True)
+ if actions:
+ if previous_phase != "open" \
+ and rule.get("cancel_action_phases", "always") == "open":
+ log("Do not execute cancelling actions, event %s's phase is not 'open' but '%s'" %
+ (event["id"], previous_phase))
+ else:
+ do_event_actions(actions, event, is_cancelling = True)
to_delete.append(nr)
for nr in to_delete[::-1]:
diff --git a/mkeventd/web/plugins/wato/mkeventd.py b/mkeventd/web/plugins/wato/mkeventd.py
index b3a2b86..da99f10 100644
--- a/mkeventd/web/plugins/wato/mkeventd.py
+++ b/mkeventd/web/plugins/wato/mkeventd.py
@@ -301,6 +301,16 @@ vs_mkeventd_rule = Dictionary(
choices = mkeventd.action_choices,
)
),
+ ( "cancel_action_phases",
+ DropdownChoice(
+ title = _("Do Cancelling-Actions when..."),
+ choices = [
+ ( "always", _("Always when an event is being cancelled")),
+ ( "open", _("Only when the cancelled event is in phase OPEN")),
+ ],
+ help = _("With this setting you can prevent actions to be executed when "
+ "events are being cancelled that are in the phases DELAYED or COUNTING."),
+ )),
( "autodelete",
Checkbox(
title = _("Automatic Deletion"),
@@ -689,7 +699,7 @@ vs_mkeventd_rule = Dictionary(
( _("Rule Properties"), [ "id", "description", "comment", "docu_url", "disabled" ] ),
( _("Matching Criteria"), [ "match", "match_host", "match_ipaddress", "match_application", "match_priority", "match_facility",
"match_sl", "match_ok", "cancel_priority", "match_timeperiod" ]),
- ( _("Outcome & Action"), [ "state", "sl", "contact_groups", "actions", "cancel_actions", "drop", "autodelete" ]),
+ ( _("Outcome & Action"), [ "state", "sl", "contact_groups", "actions", "cancel_actions", "cancel_action_phases", "drop", "autodelete" ]),
( _("Counting & Timing"), [ "count", "expect", "delay", "livetime", ]),
( _("Rewriting"), [ "set_text", "set_host", "set_application", "set_comment", "set_contact" ]),
],
Module: check_mk
Branch: master
Commit: 8686677ecd19232221c1367d02ef95a6b6b8efa7
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=8686677ecd1923…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Apr 22 16:24:20 2015 +0200
#2212 FIX oracle_tablespaces: Fix plugin output in case of detected problem in Autoextend settings
The checkout would output <tt>NO AUTOEXTEND(!!)</tt> if it had detected that autoextend
was <b>on</b> but should be off. The <tt>NO</tt> has now been removed in order to fix
the output. The vice versa case has also been fixed.
---
.werks/2212 | 12 ++++++++++++
ChangeLog | 1 +
checks/oracle_tablespaces | 4 ++--
3 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/.werks/2212 b/.werks/2212
new file mode 100644
index 0000000..4d99ea2
--- /dev/null
+++ b/.werks/2212
@@ -0,0 +1,12 @@
+Title: oracle_tablespaces: Fix plugin output in case of detected problem in Autoextend settings
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.7i1
+Date: 1429712580
+
+The checkout would output <tt>NO AUTOEXTEND(!!)</tt> if it had detected that autoextend
+was <b>on</b> but should be off. The <tt>NO</tt> has now been removed in order to fix
+the output. The vice versa case has also been fixed.
diff --git a/ChangeLog b/ChangeLog
index cbfcae9..9fa75dd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -339,6 +339,7 @@
* 2213 FIX: cisco_temperature: Fixed behaviour in cases where device reports status but no temperature...
* 2069 FIX: netapp_api_disk.summary: fixed one missing disk in summary check...
* 2070 FIX: agent_netapp: fixed exception when a channel has no shelf-list configured
+ * 2212 FIX: oracle_tablespaces: Fix plugin output in case of detected problem in Autoextend settings...
Multisite:
* 1758 Improved exception hander: Shows details without additional debug request, added mailto link for error report...
diff --git a/checks/oracle_tablespaces b/checks/oracle_tablespaces
index c1784b7..92b0154 100644
--- a/checks/oracle_tablespaces
+++ b/checks/oracle_tablespaces
@@ -205,10 +205,10 @@ def check_oracle_tablespaces(item, params, info):
# Check autoextend status if parameter not set to None
if autoext != None:
if autoext and num_extensible == 0:
- infotext += ", AUTOEXTEND(!!)"
+ infotext += ", NO AUTOEXTEND(!!)"
status = 2
elif not autoext and num_extensible > 0:
- infotext += ", NO AUTOTEXTEND(!!)"
+ infotext += ", AUTOTEXTEND(!!)"
status = 2
elif num_extensible > 0:
infotext += ", autoextend"
Module: check_mk
Branch: master
Commit: 5051382fccad2aba0279cb658e506b0209db5a7d
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5051382fccad2a…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Wed Apr 22 13:53:53 2015 +0200
#2182 FIX Fixed services randomly becoming stale when using CMC
Fixed update of services when host has just been added and fist
performed check was the discovery check.
---
.werks/2182 | 11 +++++++++++
ChangeLog | 1 +
2 files changed, 12 insertions(+)
diff --git a/.werks/2182 b/.werks/2182
new file mode 100644
index 0000000..e77ca1e
--- /dev/null
+++ b/.werks/2182
@@ -0,0 +1,11 @@
+Title: Fixed services randomly becoming stale when using CMC
+Level: 1
+Component: core
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.7i1
+Date: 1429703582
+
+Fixed update of services when host has just been added and fist
+performed check was the discovery check.
diff --git a/ChangeLog b/ChangeLog
index 84b9fd8..1909ec5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -24,6 +24,7 @@
* 2187 FIX: Avoid CLOSE_WAIT sockets for agent connection in case of timeouts...
* 2194 FIX: Avoid new discovered checks from being used without config reload
* 2180 FIX: cmk -D showed always "bulkwalk: no" for SNMPv3 hosts (which is wrong)...
+ * 2182 FIX: Fixed services randomly becoming stale when using CMC...
Checks & Agents:
* 1665 agent_netapp: New special agent for NetApp monitoring via Web-API...
Module: check_mk
Branch: master
Commit: 73779006d210a7cb9839e5389e9f0c4cfa73efd6
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=73779006d210a7…
Author: Konstantin Büttner <kb(a)mathias-kettner.de>
Date: Wed Apr 22 11:48:22 2015 +0200
Fix some English texts
---
web/htdocs/valuespec.py | 10 +++++-----
web/plugins/wato/active_checks.py | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/web/htdocs/valuespec.py b/web/htdocs/valuespec.py
index 9cf3180..6dfc4d6 100644
--- a/web/htdocs/valuespec.py
+++ b/web/htdocs/valuespec.py
@@ -835,7 +835,7 @@ class ListOf(ValueSpec):
self._allow_empty = kwargs.get("allow_empty", True)
self._empty_text = kwargs.get("empty_text")
if not self._empty_text:
- self._empty_text = _("Please specify at least on entry")
+ self._empty_text = _("Please specify at least one entry")
def del_button(self, vp, nr):
js = "valuespec_listof_delete(this, '%s', '%s')" % (vp, nr)
@@ -1182,7 +1182,7 @@ class DropdownChoice(ValueSpec):
self._label = kwargs.get("label")
self._prefix_values = kwargs.get("prefix_values", False)
self._sorted = kwargs.get("sorted", False)
- self._empty_text = kwargs.get("empty_text", _("There are not defined any elements for this selection yet."))
+ self._empty_text = kwargs.get("empty_text", _("There are no elements defined for this selection yet."))
self._no_preselect = kwargs.get("no_preselect", False)
self._no_preselect_value = kwargs.get("no_preselect_value", None)
@@ -1974,7 +1974,7 @@ class AbsoluteDate(ValueSpec):
if self._allow_empty:
return None
else:
- raise MKUserError(varname, _("Please enter a correct number"))
+ raise MKUserError(varname, _("Please enter a valid number"))
if part < mmin or part > mmax:
raise MKUserError(varname, _("The value for %s must be between %d and %d" % (_(what), mmin, mmax)))
parts.append(part)
@@ -2141,7 +2141,7 @@ class TimeofdayRange(ValueSpec):
self._bounds[0].validate_value(value[0], varprefix + "_from")
self._bounds[1].validate_value(value[1], varprefix + "_until")
if value[0] > value[1]:
- raise MKUserError(varprefix + "_until", _("The <i>from</i> time must not be greater then the <i>until</i> time."))
+ raise MKUserError(varprefix + "_until", _("The <i>from</i> time must not be later then the <i>until</i> time."))
ValueSpec.custom_validate(self, value, varprefix)
month_names = [
@@ -2978,7 +2978,7 @@ class ElementSelection(ValueSpec):
ValueSpec.__init__(self, **kwargs)
self._loaded_at = None
self._label = kwargs.get("label")
- self._empty_text = kwargs.get("empty_text", _("There are not defined any elements for this selection yet."))
+ self._empty_text = kwargs.get("empty_text", _("There are no elements defined for this selection yet."))
def load_elements(self):
if self._loaded_at != id(html):
diff --git a/web/plugins/wato/active_checks.py b/web/plugins/wato/active_checks.py
index 4a44607..db7189b 100644
--- a/web/plugins/wato/active_checks.py
+++ b/web/plugins/wato/active_checks.py
@@ -29,7 +29,7 @@ register_rulegroup("activechecks",
_("Configure active networking checks like HTTP and TCP"))
group = "activechecks"
-# This elements are also used in check_parameters.py
+# These elements are also used in check_parameters.py
check_icmp_params = [
( "rta",
Tuple(
Module: check_mk
Branch: master
Commit: 80879c6c94f245ba8728fb01b30b5b758ca239d3
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=80879c6c94f245…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Apr 22 10:16:25 2015 +0200
#2210 check_bi_aggr: new option for honoring downtimes and acknowledgements
The active check <i>Check State of BI Aggregation</i> now has two new
options for handling aggregates that are in a scheduled downtime or
that are acknowledged (visit the according WATO rule set for details).
In each of the two cases you can have the state of such an aggregate
shifted to OK are at most WARN.
---
.werks/2210 | 13 +++++
ChangeLog | 1 +
checks/check_bi_aggr | 7 ++-
doc/treasures/active_checks/.f12 | 1 +
doc/treasures/active_checks/check_bi_aggr | 89 +++++++++++++++++++----------
web/htdocs/valuespec.py | 6 ++
web/plugins/views/bi.py | 12 ++++
web/plugins/views/builtin.py | 9 ++-
web/plugins/wato/active_checks.py | 22 ++++++-
9 files changed, 127 insertions(+), 33 deletions(-)
Diff: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commitdiff;h=80879c6c94…