Merge "fixed template sample"

This commit is contained in:
Jenkins 2016-08-16 13:37:35 +00:00 committed by Gerrit Code Review
commit 098e9bec88
2 changed files with 73 additions and 62 deletions

View File

@ -1,62 +0,0 @@
metadata:
name: deduced_host_disk_space_to_instance_at_risk
description: when there is low disk space on the host, show implications on the instances
definitions:
entities:
- entity:
category: ALARM
type: Free disk space is less than 20% on volume /
template_id: host_alarm
- entity:
category: ALARM
type: instance_at_risk
template_id: instance_alarm
- entity:
category: RESOURCE
type: nova.host
template_id: host
- entity:
category: RESOURCE
type: nova.instance
template_id: instance
relationships:
- relationship:
source: host_alarm
relationship_type: on
target: host
template_id : alarm_on_host
- relationship:
source: host
relationship_type: contains
target: instance
template_id : host_contains_instance
- relationship:
source: instance_alarm
relationship_type: on
target: instance
template_id : alarm_on_instance
scenarios:
- scenario:
condition: alarm_on_host and host_contains_instance
actions:
- action:
action_type: raise_alarm
properties:
alarm_name: instance_at_risk
severity: warning
action_target:
target: instance
- action:
action_type: set_state
properties:
state: suboptimal
action_target:
target: instance
- scenario:
condition: alarm_on_host and host_contains_instance and alarm_on_instance
actions:
- action:
action_type: add_causal_relationship
action_target:
source: host_alarm
target: instance_alarm

View File

@ -0,0 +1,73 @@
metadata:
name: host_high_cpu_load_scenarios
description: scenarios triggered by high cpu load on physical
definitions:
entities:
- entity:
category: ALARM
type: zabbix
rawtext: Processor load is too high on {HOST.NAME}
template_id: zabbix_alarm
- entity:
category: ALARM
type: vitrage
name: CPU performance degradation
template_id: instance_alarm
- entity:
category: RESOURCE
type: nova.instance
template_id: instance
- entity:
category: RESOURCE
type: nova.host
template_id: host
relationships:
- relationship:
source: zabbix_alarm
relationship_type: on
target: host
template_id : high_cpu_load_on_host
- relationship:
source: host
relationship_type: contains
target: instance
template_id : host_contains_instance
- relationship:
source: instance_alarm
relationship_type: on
target: instance
template_id : alarm_on_instance
scenarios:
- scenario:
condition: high_cpu_load_on_host and host_contains_instance
actions:
- action:
action_type: raise_alarm
action_target:
target: instance
properties:
alarm_name: CPU performance degradation
severity: warning
- action:
action_type: set_state
action_target:
target: instance
properties:
state: SUBOPTIMAL
- scenario:
condition: high_cpu_load_on_host and host_contains_instance and alarm_on_instance
actions:
- action:
action_type: add_causal_relationship
action_target:
source: zabbix_alarm
target: instance_alarm
- scenario:
condition: high_cpu_load_on_host
actions:
- action:
action_type: set_state
action_target:
target: host
properties:
state: SUBOPTIMAL