Monitored service (service)

The service model is used to represent a monitored service.

A service is a monitored feature attached to an host.and monitored by your Alignak framework.

Property Type Required Default Relation
boolean   False  
Element overall state
integer   3  
objectid True   realm
boolean   True  
Template fields
list   []  
objectid list   [] service
Template from host
boolean   False  
objectid list     user
objectid list     user
objectid list     user
Actions URL
Active checks enabled
boolean   True  
Business impact
integer   2  
Business impact modulations
list   []  
BR downtime as ack
boolean   False  
BR host notification options
list   [‘d’, ‘u’, ‘r’, ‘f’, ‘s’]  
BR output template
BR service notification options
list   [‘w’, ‘u’, ‘c’, ‘r’, ‘f’, ‘s’]  
BR smart notifications
boolean   False  
Check command
objectid     command
Check command arguments
Check freshness
boolean   False  
Check interval
integer   5  
Check period
objectid     timeperiod
Checks modulations
list   []  
list   []  
Custom variables
dict   {}  
Definition order
integer   100  
Display name
Duplicate for each
objectid list   [] serviceescalation
Event handler
objectid   None command
Event handler arguments
Event handler enabled
boolean   False  
First notification delay
integer   0  
Flapping detection enabled
boolean   True  
Flapping detection options
list   [‘o’, ‘w’, ‘c’, ‘u’, ‘x’]  
Freshness state
string   x  
Freshness threshold
integer   0  
High flapping threshold
integer   50  
Linked host
objectid     host
boolean   True  
objectid list   [] hostgroup
Imported from
string   unknown  
Initial state
string   x  
boolean   False  
BR labels
list   []  
Low flapping threshold
integer   25  
boolean   False  
Acknowledgement type
integer   1  
Current attempt number
integer   0  
boolean   False  
Execution time
float   0.0  
Grafana available
boolean   False  
Grafana identifier
integer   0  
Last check time
integer   0  
Last time hard state changed
integer   0  
Last notification sent
integer   0  
Last state
string   UNKNOWN  
Last state changed
integer   0  
Last state type
string   HARD  
Last time critical
integer   0  
Last time ok
integer   0  
Last time unknown
integer   0  
Last time unreachable
integer   0  
Last time warning
integer   0  
float   0.0  
Long output
Next check
integer   0  
Check type
boolean   False  
Performance data
string   UNKNOWN  
Last time state changed
integer   0  
State identifier
integer   3  
State type
string   HARD  
Macros modulations
list   []  
Maintenance period
objectid     timeperiod
Maximum check attempts
integer   1  
boolean   False  
Service name
string True    
Notes URL
Notifications interval
integer   60  
Notifications options
list   [‘w’, ‘u’, ‘c’, ‘r’, ‘f’, ‘s’, ‘x’]  
Notifications period
objectid     timeperiod
Notifications enabled
boolean   True  
boolean   True  
Passive checks enabled
boolean   True  
Poller tag
Performance data enabled
boolean   True  
Reactionner tag
Results modulations
list   []  
Retry interval
integer   0  
integer   3  
objectid list   [] service
Snapshot command
objectid     command
Snapshot criteria
list   [‘w’, ‘c’, ‘x’]  
Snapshot enabled
boolean   False  
Snapshot interval
integer   5  
Snapshot period
objectid     timeperiod
Stalking options
list   []  
list   []  
Time to orphanage
integer   300  
Trending policies
list   []  
boolean   False  
Trigger name
Notifications users groups
objectid list   [] usergroup
Notifications users
objectid list   [] user

_is_template: Indicate if this element is a template or a real element

_overall_state_id: The overall state is a synthesis state that considers the element state, its acknowledgement and its downtime.

_realm: Realm this element belongs to.

_sub_realm: Is this element visible in the sub-realms of its realm?

_template_fields: If this element is not a template, this field contains the list of the fields linked to the templates this element is linked to

_templates: List of templates this element is linked to.

_templates_from_host_template: This element was created as a service from an host template.

action_url: Element actions URL. Displayed in the Web UI as some available actions. Note that a very specific text format must be used for this field, see the Web UI documentation.

aggregation: Group the services is belonging to. Used for the Web UI tree view.

alias: Element friendly name used by the Web User Interface.

business_impact: The business impact level indicates the level of importance of this element. The highest value the most important is the element.

Allowed values: [0, 1, 2, 3, 4, 5]

business_impact_modulations: Not yet implemented (#116).

business_rule_downtime_as_ack: Not yet implemented (#146)

business_rule_host_notification_options: Not yet implemented (#146)

Allowed values: [‘d’, ‘u’, ‘r’, ‘f’, ‘s’, ‘n’]

business_rule_output_template: Not yet implemented (#146)

business_rule_service_notification_options: Not yet implemented (#146)

Allowed values: [‘w’, ‘u’, ‘c’, ‘r’, ‘f’, ‘s’, ‘n’]

business_rule_smart_notifications: Not yet implemented (#146)

check_command: Command that will be executed to check if the element is ok.

check_command_args: Separate arguments with !. For example, if your have 2 arguments, enter test1!test2

check_freshness: Passive checks only. If the freshness check is enabled, and no passive check has been received since freshness_threshold seconds, the state will be forced to freshness_state.

check_interval: Active checks only. Number of minutes between the periodical checks.

check_period: Time period during which active / passive checks can be made.

checkmodulations: Not yet implemented (#114).

definition_order: Priority level if several elements have the same name

display_name: Old Nagios stuff. To be deprecated

duplicate_foreach: To be deprecated. Shinken stuff…

escalations: List of the escalations applied to this element. Not yet implemented.

event_handler: Command that should run whenever a change in the element state is detected.

first_notification_delay: Number of minutes to wait before sending out the first problem notification when a non-ok state is detected. If you set this value to 0, the first notification will be sent-out immediately.

flap_detection_enabled: Flapping occurs when an element changes state too frequently, resulting in a storm of problem and recovery notifications. Once an element is detected as flapping, all its notifications are blocked.

flap_detection_options: States involved in the flapping detection logic.

Allowed values: [‘o’, ‘w’, ‘c’, ‘u’, ‘x’]

freshness_state: Passive checks only. The state that will be forced by Alignak when the freshness check fails.

Allowed values: [‘o’, ‘w’, ‘c’, ‘u’, ‘x’]

freshness_threshold: Passive checks only. Number of seconds for the freshness check to force the freshness_state. If this value is set to 0, Alignak will use a default value (3600 seconds)

host: Host the service is linked to

host_dependency_enabled: Unset this to remove the dependency between this service and its parent host. Used for volatile services that need notification related to itself and not depend on the host notifications.

icon_image: Old Nagios stuff. To be deprecated

icon_image_alt: Old Nagios stuff. To be deprecated

icon_set: Old Nagios stuff. To be deprecated

imported_from: Item importation source (alignak-backend-import, …)

initial_state: Alignak sets this default state until a check happen

Allowed values: [‘o’, ‘w’, ‘c’, ‘u’, ‘x’]

is_volatile: To make it simple, volatile services ignore the hard state transition and they always notify when they are in a non ok state. For more information, read the Alignak documentation about this type of services.

labels: Not yet implemented (#146)

ls_acknowledged: Currently acknowledged

ls_downtimed: Currently downtimed

ls_execution_time: Last check execution time

ls_grafana: This element has a Grafana panel available

ls_grafana_panelid: Grafana panel identifier

ls_last_check: Last check timestamp

ls_last_hard_state_changed: Last time this element hard state has changed.

ls_last_state: Former state


ls_last_state_changed: Last state changed timestamp

ls_last_state_type: Former state type

Allowed values: [‘HARD’, ‘SOFT’]

ls_last_time_critical: Last time this element was Unknown.

ls_last_time_ok: Last time this element was Ok.

ls_last_time_unknown: Last time this element was Unknown.

ls_last_time_unreachable: Last time this element was Unreachable.

ls_last_time_warning: Last time this element was Warning.

ls_latency: Last check latency

ls_long_output: Last check long output

ls_next_check: Next check timestamp

ls_output: Last check output

ls_passive_check: Last check was active or passive?

ls_perf_data: Last check performance data

ls_state: Current state


ls_state_changed: Last time this element state has changed.

ls_state_id: Current state identifier. O: OK, 1: WARNING, 2: CRITICAL, 3: UNKNOWN, 4: UNREACHABLE

Allowed values: [0, 1, 2, 3, 4]

ls_state_type: Current state type

Allowed values: [‘HARD’, ‘SOFT’]

macromodulations: Not yet implemented (#115).

maintenance_period: The maintenance period of a service is a time period that defines an equivalent of scheduled downtimes for the service.

max_check_attempts: Active checks only. Number of times the check command will be executed if it returns a state other than Ok. Setting this value to 1 will raise an alert without any retry.

name: Service name (eg. service_description)

notes: Element notes. Free text to store element information.

notes_url: Element notes URL. Displayed in the Web UI as some URL to be navigatesd. Note that a very specific text format must be used for this field, see the Web UI documentation.

notification_interval: Number of minutes to wait before re-sending the notifications if the problem is still present. If you set this value to 0, only one notification will be sent out.

notification_options: List of the notifications types that can be sent.

Allowed values: [‘w’, ‘u’, ‘c’, ‘r’, ‘f’, ‘s’, ‘x’, ‘n’]

notification_period: Time period during which notifications can be sent.

poller_tag: Set a value for this element checks to be managed by a dedicated poller.

reactionner_tag: Set a value for this element notifications to be managed by a dedicated reactionner.

resultmodulations: Not yet implemented (#116).

retry_interval: Active checks only. Number of minutes to wait before scheduling a re-check. Checks are rescheduled at the retry interval when they have changed to a non-ok state. Once it has been retried max_check_attempts times without a change in its status, it will revert to being scheduled at its check_interval period.

service_dependencies: List of the services that this service is dependent of for notifications. A default service_dependency will exist with default values (notification_failure_criteria as “u,c,w” and no dependency_period).

snapshot_command: Command executed for the snapshot

snapshot_criteria: Execute the snapshot command when the state matches one of the criteria

snapshot_interval: Minimum interval between two snapshots

snapshot_period: Time period when the snapshot feature is active

stalking_options: When enabled for a specific state, Alignak will add an information log for each element check even if the state did not changed.

Allowed values: [‘o’, ‘w’, ‘u’, ‘c’, ‘x’]

tags: List of tags for this element. Intended to set tags by the Web UI

time_to_orphanage: To be clearly understood and documented…

trigger_broker_raise_enabled: To be documented

trigger_name: To be documented

usergroups: List of the users groups that will receive the sent notifications.

users: List of the users that will receive the sent notifications.