Add alarm for Horizon HTTP 5xx errors

The patch also fixes the GSE horizon-(web|ui) wrong definition.

Change-Id: I4a7a64c87ac8c9fe3929ec98ebc8de51e9292a26
This commit is contained in:
Swann Croiset 2016-09-16 11:35:26 +02:00
parent 553d2040cc
commit 015ad15ec4
3 changed files with 32 additions and 8 deletions

View File

@ -226,7 +226,9 @@ lma::collector::infrastructure_alerting::password: <%= @nagios_password %>
}
$storage_options = hiera_hash('storage', {})
$tls_enabled = hiera('public_ssl', false)
$public_ssl = hiera('public_ssl', {})
$tls_enabled = $public_ssl['horizon'] or false
$ceilometer = hiera_hash('ceilometer', {})
$ceilometer_enabled = pick($ceilometer['enabled'], false)
$contrail_plugin = hiera('contrail', false)

View File

@ -726,6 +726,21 @@ lma_collector:
window: 60
periods: 1
function: diff
- name: 'horizon-web-http-errors'
description: 'Too many 5xx HTTP errors have been detected on horizon'
severity: 'warning'
enabled: 'true'
trigger:
logical_operator: 'or'
rules:
- metric: haproxy_backend_response_5xx
fields:
backend: 'horizon-web || horizon-https'
relational_operator: '>'
threshold: 0
window: 60
periods: 1
function: diff
- name: 'keystone-logs-error'
description: 'Too many errors have been detected in Keystone logs'
severity: 'warning'
@ -1321,6 +1336,16 @@ lma_collector:
activate_alerting: true
alarms:
http_errors: ['keystone-admin-api-http-errors']
<% if @tls_enabled then -%>
horizon-https:
<% else -%>
horizon-web:
<% end -%>
apply_to_node: controller
enable_notification: false
activate_alerting: true
alarms:
http_errors: ['horizon-web-http-errors']
nova-instances:
#TODO(scroiset): apply on compute nodes
apply_to_node: controller

View File

@ -343,17 +343,14 @@ lma_collector:
- backends
<% if @tls_enabled then -%>
horizon-https:
policy: highest_severity
group_by: member
members:
- backends
<% else -%>
horizon-ui:
horizon-web:
<% end -%>
policy: highest_severity
group_by: member
members:
- backends
<% end -%>
- http_errors
<% if not @storage_options["objects_ceph"] then -%>
swift-api:
policy: highest_severity
@ -685,7 +682,7 @@ lma_collector:
<% if @tls_enabled then -%>
- horizon-https
<% else -%>
- horizon-ui
- horizon-web
<% end -%>
- controller
hints: