Module: check_mk
Branch: master
Commit: 38e7a571ca2c6a625834758ff9db9368381dafc4
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=38e7a571ca2c6a…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu Feb 26 14:42:42 2015 +0100
Added new service description Filesystem to example BI rules
---
web/htdocs/bi.py | 6 +++---
web/plugins/wato/bi.py | 2 ++
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/web/htdocs/bi.py b/web/htdocs/bi.py
index a0f4fc8..27ac5b6 100644
--- a/web/htdocs/bi.py
+++ b/web/htdocs/bi.py
@@ -718,13 +718,13 @@ def compile_aggregation_rule(aggr_type, rule, args, lvl):
)
if len(rule) != 4:
- raise MKConfigError(_("<h3>Invalid aggregation rule</h1>"
+ raise MKConfigError(_("<b>Invalid aggregation
rule</b><br><br>"
"Aggregation rules must contain four elements: description, argument
list, "
"aggregation function and list of nodes. Your rule has %d elements:
"
"<pre>%s</pre>") % (len(rule),
pprint.pformat(rule)))
if lvl == 50:
- raise MKConfigError(_("<h3>Depth limit reached</h3>"
+ raise MKConfigError(_("<b>Depth limit
reached</b><br><br>"
"The nesting level of aggregations is limited to 50. You either
configured "
"too many levels or built an infinite recursion. This happened in
rule <pre>%s</pre>")
% pprint.pformat(rule))
@@ -733,7 +733,7 @@ def compile_aggregation_rule(aggr_type, rule, args, lvl):
# check arguments and convert into dictionary
if len(arglist) != len(args):
- raise MKConfigError(_("<h1>Invalid rule usage</h1>"
+ raise MKConfigError(_("<b>Invalid rule
usage</b><br><br>"
"The rule '%s' needs %d arguments:
<tt>%s</tt><br>"
"You've specified %d arguments: <tt>%s</tt>") %
(
description, len(arglist), repr(arglist), len(args), repr(args)))
diff --git a/web/plugins/wato/bi.py b/web/plugins/wato/bi.py
index 7d1e423..b2781e3 100644
--- a/web/plugins/wato/bi.py
+++ b/web/plugins/wato/bi.py
@@ -138,6 +138,7 @@ aggregation_rules["filesystems"] = (
( "$HOST$", "Disk|MD" ),
( "multipathing", [ "$HOST$" ]),
( FOREACH_SERVICE, "$HOST$", "fs_(.*)", "filesystem",
[ "$HOST$", "$1$" ] ),
+ ( FOREACH_SERVICE, "$HOST$", "Filesystem(.*)",
"filesystem", [ "$HOST$", "$1$" ] ),
]
)
@@ -147,6 +148,7 @@ aggregation_rules["filesystem"] = (
"worst",
[
( "$HOST$", "fs_$FS$$" ),
+ ( "$HOST$", "Filesystem$FS$$" ),
( "$HOST$", "Mount options of $FS$$" ),
]
)