lists.checkmk.com
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
List overview
Download
Checkmk git commits
April 2011
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
checkmk-commits@lists.checkmk.com
2 participants
103 discussions
Start a n
N
ew thread
Check_MK Git: check_mk: Removed unused images; Cleaned up css definitions; Added fold image to view editor
by lm@mathias-kettner.de
Module: check_mk Branch: master Commit: 552d1a64f8c3ff028104c4e78d5e3f975e2c1d76 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=552d1a64f8c3ff…
Author: Lars Michelsen <lm(a)mathias-kettner.de> Date: Mon Apr 18 17:03:22 2011 +0200 Removed unused images; Cleaned up css definitions; Added fold image to view editor --- web/htdocs/check_mk.css | 107 +++++++------------- web/htdocs/htmllib.py | 2 +- web/htdocs/images/MK-mini-black.gif | Bin 1299 -> 0 bytes web/htdocs/images/MK-mini.gif | Bin 1185 -> 0 bytes .../{assumption_background.png => assume_bg.png} | Bin 222 -> 222 bytes web/htdocs/images/background-blue.jpg | Bin 13875 -> 0 bytes web/htdocs/images/background-brown.jpg | Bin 13643 -> 0 bytes web/htdocs/images/background-gold.jpg | Bin 17084 -> 0 bytes web/htdocs/images/background-gray.jpg | Bin 9539 -> 0 bytes web/htdocs/images/background-green.jpg | Bin 13467 -> 0 bytes web/htdocs/images/background-side.jpg | Bin 10549 -> 0 bytes web/htdocs/images/background-top.jpg | Bin 41727 -> 0 bytes web/htdocs/images/background.jpg | Bin 15493 -> 0 bytes web/htdocs/images/button_close14hi.png | Bin 745 -> 0 bytes web/htdocs/images/button_close14lo.png | Bin 734 -> 0 bytes web/htdocs/images/check_mk.trans.120.png | Bin 7103 -> 0 bytes web/htdocs/images/check_mk.trans.54.png | Bin 3003 -> 0 bytes web/htdocs/images/check_mk.trans.60.png | Bin 3117 -> 0 bytes web/htdocs/images/check_mk_background.jpg | Bin 63216 -> 0 bytes web/htdocs/images/closed.gif | Bin 78 -> 0 bytes web/htdocs/images/metanav_50.png | Bin 236 -> 0 bytes web/htdocs/images/metanav_50_hi.png | Bin 264 -> 0 bytes web/htdocs/images/metanav_button_20.png | Bin 300 -> 0 bytes web/htdocs/images/metanav_button_20_hi.png | Bin 287 -> 0 bytes web/htdocs/images/metanav_button_30.png | Bin 297 -> 0 bytes web/htdocs/images/metanav_button_30_hi.png | Bin 288 -> 0 bytes web/htdocs/images/metanav_button_40.png | Bin 320 -> 0 bytes web/htdocs/images/mk_logo_klein.png | Bin 1276 -> 0 bytes web/htdocs/images/mk_logo_small.gif | Bin 0 -> 453 bytes web/htdocs/images/open.gif | Bin 77 -> 0 bytes ...frame_background.jpg => sidebar_background.jpg} | Bin 49576 -> 49576 bytes .../{sidebar_unten.png => sidebar_bottom.png} | Bin 483 -> 483 bytes .../images/{sidebar_oben.png => sidebar_top.png} | Bin 5897 -> 5897 bytes web/htdocs/images/tree_closed.png | Bin 2428 -> 0 bytes web/htdocs/images/whiteglass.png | Bin 193 -> 0 bytes web/htdocs/images/whiteline_dot.gif | Bin 43 -> 0 bytes web/htdocs/js/check_mk.js | 36 ++++--- web/htdocs/permissions.py | 2 +- web/htdocs/views.py | 26 ++--- web/htdocs/wato.py | 2 +- web/plugins/views/bi.py | 2 +- 41 files changed, 75 insertions(+), 102 deletions(-) Diff:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commitdiff;h=552d1a64f8…
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: A lot of additional styling cleanups
by lm@mathias-kettner.de
Module: check_mk Branch: master Commit: 1da3865e6e8a01eaa86162a96bf756b402c0bd40 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=1da3865e6e8a01…
Author: Lars Michelsen <lm(a)mathias-kettner.de> Date: Tue Apr 19 11:29:59 2011 +0200 A lot of additional styling cleanups --- web/htdocs/check_mk.css | 1114 +++++++++++++++++----------------------- web/htdocs/main.py | 1 - web/htdocs/page_logwatch.py | 2 +- web/htdocs/wato.py | 8 +- web/plugins/sidebar/search.py | 12 +- web/plugins/sidebar/shipped.py | 43 +- web/plugins/views/layouts.py | 6 +- 7 files changed, 517 insertions(+), 669 deletions(-) Diff:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commitdiff;h=1da3865e6e…
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: smart check: Renamed *default_values to *default_levels vars
by lm@mathias-kettner.de
Module: check_mk Branch: master Commit: 08be083517b59514898b72c0a0f682b96fe7ff02 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=08be083517b595…
Author: Lars Michelsen <lm(a)mathias-kettner.de> Date: Tue Apr 26 13:19:27 2011 +0200 smart check: Renamed *default_values to *default_levels vars --- checkman/smart.stats | 4 ++-- checkman/smart.temp | 2 +- checks/smart | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/checkman/smart.stats b/checkman/smart.stats index dd76728..8fe1c7f 100644 --- a/checkman/smart.stats +++ b/checkman/smart.stats @@ -20,7 +20,7 @@ inventory: examples: # These are the default thresholds of the check. - smart_stats_default_values = { + smart_stats_default_levels = { 'realloc_events': (1, 1), 'realloc_sectors': (1, 1), 'spin_retries': (1, 1), @@ -38,5 +38,5 @@ params(dict from string to (int, int)): A python dictionary which contains threshold threshold for each supported value. [configuration] -smart_stats_default_values (dict from string to (int, int)): default levels +smart_stats_default_levels (dict from string to (int, int)): default levels used for all inventorized checks. diff --git a/checkman/smart.temp b/checkman/smart.temp index a2b8fcd..e21819b 100644 --- a/checkman/smart.temp +++ b/checkman/smart.temp @@ -26,7 +26,7 @@ perfdata: examples: # Set the warning threshold to 40 and critical to 50 degrees celsius. - smart_temp_default_values = (35, 40) + smart_temp_default_levels = (35, 40) [parameters] warning (int): The degrees celsius to trigger a WARNING state diff --git a/checks/smart b/checks/smart index 087e624..a3ddae9 100644 --- a/checks/smart +++ b/checks/smart @@ -45,8 +45,8 @@ #/dev/sda ATA WDC_SSC-D0128SC- 173 Unknown_Attribute 0x0012 100 100 000 Old_age Always - 4217788040605 -smart_temp_default_values = (35, 40) -smart_stats_default_values = { +smart_temp_default_levels = (35, 40) +smart_stats_default_levels = { 'realloc_events': (1, 1), 'realloc_sectors': (1, 1), 'spin_retries': (1, 1), @@ -72,9 +72,9 @@ def inventory_smart(checktype, info): 'Command_Timeout', 'End-to-End_Error', 'Reported_Uncorrect', 'UDMA_CRC_Error_Count', ] \ and not (line[0], None) in inventory: - inventory.append((line[0], None, 'smart_stats_default_values')) + inventory.append((line[0], None, 'smart_stats_default_levels')) elif checktype == 'smart.temp' and line[4] == 'Temperature_Celsius': - inventory.append((line[0], None, 'smart_temp_default_values')) + inventory.append((line[0], None, 'smart_temp_default_levels')) return inventory
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: Merge branch 'master' of ssh://git.mathias-kettner. de/var/www/80/git.mathias-kettner.de/check_mk
by lm@mathias-kettner.de
Module: check_mk Branch: master Commit: 6fecf1ca8d85e88c6c6a07b61ceb68c785ddd0d1 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=6fecf1ca8d85e8…
Author: Lars Michelsen <lm(a)mathias-kettner.de> Date: Tue Apr 26 13:51:58 2011 +0200 Merge branch 'master' of ssh://git.mathias-kettner.de/var/www/80/git.mathias-kettner.de/check_mk ---
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: BI: better example for BI
by git@mathias-kettner.de
Module: check_mk Branch: master Commit: 5dad946919f116ee52cf238f319dbf4896e3ebf1 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5dad946919f116…
Author: Mathias Kettner <mk(a)mathias-kettner.de> Date: Mon Apr 25 13:06:50 2011 +0200 BI: better example for BI --- doc/bi-example.mk | 41 ++++++++++++++++++++++++++++++----------- 1 files changed, 30 insertions(+), 11 deletions(-) diff --git a/doc/bi-example.mk b/doc/bi-example.mk index 82bed60..129aa10 100644 --- a/doc/bi-example.mk +++ b/doc/bi-example.mk @@ -6,11 +6,10 @@ aggregation_rules["host"] = ( [ "HOST" ], "worst", [ - ( "$HOST$", HOST_STATE ), + ( "general", [ "$HOST$" ] ), + ( "performance", [ "$HOST$" ] ), ( "filesystems", [ "$HOST$" ] ), - ( "cpuandmem", [ "$HOST$" ] ), ( "networking", [ "$HOST$" ] ), - ( "checkmk", [ "$HOST$" ] ), ( "applications", [ "$HOST$" ] ), ( "logfiles", [ "$HOST$" ] ), ( "hardware", [ "$HOST$" ] ), @@ -18,14 +17,35 @@ aggregation_rules["host"] = ( ] ) +aggregation_rules["general"] = ( + "General State", + [ "HOST" ], + "worst", + [ + ( "$HOST$", HOST_STATE ), + ( "$HOST$", "Uptime" ), + ( "checkmk", [ "$HOST$" ] ), + ] +) + aggregation_rules["filesystems"] = ( - "Filesystems", + "Disk & Filesystems", [ "HOST" ], "worst", [ - ( HIDDEN, "$HOST$", "fs_" ), - ( "$HOST$", "Mount|Disk" ), + ( "$HOST$", "Disk|MD" ), ( "multipathing", [ "$HOST$" ]), + ( FOREACH_SERVICE, "$HOST$", "fs_(.*)", "filesystem", [ "$HOST$", "$1$" ] ), + ] +) + +aggregation_rules["filesystem"] = ( + "$FS$", + [ "HOST", "FS" ], + "worst", + [ + ( "$HOST$", "fs_$FS$$" ), + ( "$HOST$", "Mount options of $FS$$" ), ] ) @@ -38,12 +58,12 @@ aggregation_rules["multipathing"] = ( ] ) -aggregation_rules["cpuandmem"] = ( - "CPU, Kernel, Memory", +aggregation_rules["performance"] = ( + "Performance", [ "HOST" ], "worst", [ - ( "$HOST$", "CPU|Memory|Kernel|Number of threads" ), + ( "$HOST$", "CPU|Memory|Vmalloc|Kernel|Number of threads" ), ] ) @@ -61,8 +81,7 @@ aggregation_rules["networking"] = ( [ "HOST" ], "worst", [ - ( "$HOST$", "NFS" ), - ( FOREACH_SERVICE, "$HOST$", "NIC ([a-z]*).* counters", "nic", [ "$HOST$", "$1$" ] ), + ( "$HOST$", "NFS|Interface|TCP" ), ] )
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: BI: fixed bug in REMAINING
by git@mathias-kettner.de
Module: check_mk Branch: master Commit: 6e62590ba65483635ad8451e600399fc8cc39b5c URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=6e62590ba65483…
Author: Mathias Kettner <mk(a)mathias-kettner.de> Date: Mon Apr 25 13:06:00 2011 +0200 BI: fixed bug in REMAINING --- web/htdocs/bi.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/web/htdocs/bi.py b/web/htdocs/bi.py index ceb010c..33b4c89 100644 --- a/web/htdocs/bi.py +++ b/web/htdocs/bi.py @@ -490,7 +490,7 @@ def find_remaining_services(hostspec, aggregation): "host" : hostspec, "reqhosts" : [hostspec], "service" : service, - "title" : "%s - %s" % (host, service)} + "title" : "%s - %s" % (hostspec[1], service)} for service in remaining ]
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: Small facelifting of Perf-O-Meters
by git@mathias-kettner.de
Module: check_mk Branch: master Commit: 24d43ee07e3523216d63090ed0229992c2386806 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=24d43ee07e3523…
Author: Mathias Kettner <mk(a)mathias-kettner.de> Date: Sun Apr 24 13:21:30 2011 +0200 Small facelifting of Perf-O-Meters --- web/htdocs/check_mk.css | 39 ++++++++++++++++++++++++++++------ web/htdocs/images/perfometer-bg.png | Bin 0 -> 184 bytes web/plugins/views/perfometer.py | 6 ++++- 3 files changed, 37 insertions(+), 8 deletions(-) diff --git a/web/htdocs/check_mk.css b/web/htdocs/check_mk.css index b79d6f7..da4e328 100644 --- a/web/htdocs/check_mk.css +++ b/web/htdocs/check_mk.css @@ -692,7 +692,7 @@ tr.even3 { background-color: #fea; } /* HACK */ table.services tr.data td { border: 1px solid #bbb; - padding: 3px 6px; + padding: 2px 4px; } table.services td.host { @@ -802,22 +802,47 @@ td.count { /* Performeter styling */ -td.perfometer { - padding: 1px 2px; - width: 120px; - height: 22px; - vertical-align: middle; + +table.services tr.data td.perfometer { + padding: 1px 1px 1px 0px; + width: 120px; + height: 22px; + vertical-align: middle; } -td.perfometer div.title { + +td.perfometer div.content { + position: relative; + top: 0px; + left: 1px; + width: 119px; height: 0px; + float: left; + z-index: 20; +} + +td.perfometer div.title { position: relative; top: 3px; left: 0px; width: 120px; + height: 0px; text-align: center; white-space: nowrap; + float: left; + z-index: 40; +} + +td.perfometer img.glass { + position: relative; + top: 1px; + left: 2px; + width: 118px; + height: 22px; + margin-bottom: 1px; + z-index: 30; } + td.perfometer table { width: 120px; height: 22px; diff --git a/web/htdocs/images/perfometer-bg.png b/web/htdocs/images/perfometer-bg.png new file mode 100644 index 0000000..340fe7c Binary files /dev/null and b/web/htdocs/images/perfometer-bg.png differ diff --git a/web/plugins/views/perfometer.py b/web/plugins/views/perfometer.py index f05040f..b839ea2 100644 --- a/web/plugins/views/perfometer.py +++ b/web/plugins/views/perfometer.py @@ -160,12 +160,16 @@ def paint_perfometer(row): try: title, h = perf_painter(row, check_command, perf_data) - content = "<div class=title>%s</div>%s" % (title, h) + content = '<div class=content>%s</div>' % h + content += '<div class=title>%s</div>' % title + content += '<img class=glass src="images/perfometer-bg.png">' + if 'X' in html.display_options: return "perfometer", ('<a href="%s">%s</a>' % (pnp_url(row, "service"), content)) else: return "perfometer", content + except Exception, e: if config.debug: raise
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: Fix merging of dictionary default levels
by git@mathias-kettner.de
Module: check_mk Branch: master Commit: 28298eb47d889689b93e96fd998d78b215713832 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=28298eb47d8896…
Author: Mathias Kettner <mk(a)mathias-kettner.de> Date: Sun Apr 24 13:07:10 2011 +0200 Fix merging of dictionary default levels Handle the case, where the default levels are not a dictionary (e.g. possible for filesystem_default_levels) --- modules/check_mk.py | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/modules/check_mk.py b/modules/check_mk.py index 847a6c1..ec53c54 100755 --- a/modules/check_mk.py +++ b/modules/check_mk.py @@ -3910,7 +3910,9 @@ def compute_check_parameters(host, checktype, item, params): # Merge user's default settings onto it if def_levels_varname in globals(): - new_params.update(eval(def_levels_varname)) + def_levels = eval(def_levels_varname) + if type(def_levels) == dict: + new_params.update(eval(def_levels_varname)) # Merge params from inventory onto it new_params.update(params)
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: Updated examples
by git@mathias-kettner.de
Module: check_mk Branch: master Commit: c94604e8f7e4b4add0ab5069c448765dee17f3f1 URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=c94604e8f7e4b4…
Author: Mathias Kettner <mk(a)mathias-kettner.de> Date: Sun Apr 24 11:46:46 2011 +0200 Updated examples --- doc/bi-example-oracle.mk | 4 ++-- doc/bi-example.mk | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/doc/bi-example-oracle.mk b/doc/bi-example-oracle.mk index 424ce7d..436cb61 100644 --- a/doc/bi-example-oracle.mk +++ b/doc/bi-example-oracle.mk @@ -79,7 +79,7 @@ aggregation_rules["cluster_db"] = ( ) aggregations += [ - ( "ORACLE", FOREACH, "([^:]*)", "DB_(.*)", "noncluster_db", ["$1$", "$2$" ] ), - ( "ORACLE", FOREACH, "(.*):(.*)", "DB_(.*)", "cluster_db", ["$1$", "$2$", "$3$" ] ), + ( "ORACLE", FOREACH_SERVICE, "([^:]*)", "DB_(.*)", "noncluster_db", ["$1$", "$2$" ] ), + ( "ORACLE", FOREACH_SERVICE, "(.*):(.*)", "DB_(.*)", "cluster_db", ["$1$", "$2$", "$3$" ] ), ] diff --git a/doc/bi-example.mk b/doc/bi-example.mk index 4ac9d6e..82bed60 100644 --- a/doc/bi-example.mk +++ b/doc/bi-example.mk @@ -23,7 +23,7 @@ aggregation_rules["filesystems"] = ( [ "HOST" ], "worst", [ - ( "$HOST$", "fs_" ), + ( HIDDEN, "$HOST$", "fs_" ), ( "$HOST$", "Mount|Disk" ), ( "multipathing", [ "$HOST$" ]), ] @@ -62,7 +62,7 @@ aggregation_rules["networking"] = ( "worst", [ ( "$HOST$", "NFS" ), - ( FOREACH, "$HOST$", "NIC ([a-z]*).* counters", "nic", [ "$HOST$", "$1$" ] ), + ( FOREACH_SERVICE, "$HOST$", "NIC ([a-z]*).* counters", "nic", [ "$HOST$", "$1$" ] ), ] ) @@ -111,6 +111,6 @@ aggregation_rules["other"] = ( ) aggregations += [ - ( "Hosts", FOREACH, "(.*)", "Check_MK$", "host", ["$1$"] ), + ( "Hosts", FOREACH_HOST, ALL_HOSTS, "host", ["$1$"] ), ]
13 years, 7 months
1
0
0
0
Check_MK Git: check_mk: BI: make running_on work again
by git@mathias-kettner.de
Module: check_mk Branch: master Commit: 059e9f56100c9b17b85bdbce93637591352b6f0e URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=059e9f56100c9b…
Author: Mathias Kettner <mk(a)mathias-kettner.de> Date: Thu Apr 21 16:31:25 2011 +0200 BI: make running_on work again --- web/htdocs/bi.py | 22 +++++++++++++--------- web/plugins/views/bi.py | 6 +++++- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/web/htdocs/bi.py b/web/htdocs/bi.py index fae5fba..ceb010c 100644 --- a/web/htdocs/bi.py +++ b/web/htdocs/bi.py @@ -44,7 +44,7 @@ UNKNOWN = 3 UNAVAIL = 4 service_state_names = { OK:"OK", WARN:"WARN", CRIT:"CRIT", UNKNOWN:"UNKNOWN", PENDING:"PENDING", UNAVAIL:"UNAVAILABLE"} -host_state_names = { OK:"UP", CRIT:"DOWN", UNKNOWN:"UNREACHABLE" } +host_state_names = { 0:"UP", 1:"DOWN", 2:"UNREACHABLE" } # character that separates sites and hosts @@ -669,7 +669,8 @@ def execute_leaf_node(node, status_info): aggr_state = {0:OK, 1:CRIT, 2:UNKNOWN}[host_state] state = {"state":aggr_state, "output" : host_output} if state_assumption != None: - assumed_state = {"state":assumed_state, "output" : "Assumed to be %s" % host_state_names[state_assumption]} + assumed_state = {"state": state_assumption, + "output" : "Assumed to be %s" % host_state_names[state_assumption]} else: assumed_state = None return (state, assumed_state, node) @@ -826,20 +827,23 @@ def aggr_running_on(nodes, regex): first_check = nodes[0] # extract hostname we run on - mo = re.match(regex, first_check[3]) + mo = re.match(regex, first_check[0]["output"]) # if not found, then do normal aggregation with 'worst' if not mo or len(mo.groups()) == 0: - state, text = aggregation_functions['worst'](nodes[1:]) - return state, text + ", running nowhere" + state = aggregation_functions['worst'](nodes[1:]) + state["output"] += ", running nowhere" + return state running_on = mo.groups()[0] - for host_node in nodes[1:]: - if host_node[2] == running_on: - return host_node[0], (host_node[3] + ", running on %s" % running_on) + for state, node in nodes[1:]: + for site, host in node["reqhosts"]: + if host == running_on: + state["output"] += ", running on %s" % running_on + return state # host we run on not found. Strange... - return 3, "running on unknown host '%s'" % running_on + return {"state": UNKNOWN, "output": "running on unknown host '%s'" % running_on } config.aggregation_functions['running_on'] = aggr_running_on diff --git a/web/plugins/views/bi.py b/web/plugins/views/bi.py index 35b0a63..819a75e 100644 --- a/web/plugins/views/bi.py +++ b/web/plugins/views/bi.py @@ -498,7 +498,11 @@ class BIStatusFilter(Filter): allowed_states.append(s) newrows = [] for row in rows: - if row[self.column]["state"] in allowed_states: + if row[self.column] != None: + s = row[self.column]["state"] + else: + s = None + if s in allowed_states: newrows.append(row) return newrows
13 years, 7 months
1
0
0
0
← Newer
1
2
3
4
5
6
...
11
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
Results per page:
10
25
50
100
200