An action is executed only in case an event matches a defined set of conditions.
To set a condition:
The following conditions can be set for trigger-based actions:
Condition type | Supported operators | Description |
---|---|---|
Application | = like not like |
Specify an application or an application to exclude. = - event belongs to a trigger of the item that is linked to the specified application. like - event belongs to a trigger of the item that is linked to an application containing the string. not like - event belongs to a trigger of the item that is linked to an application not containing the string. |
Host group | = <> |
Specify a host group or a host group to exclude. = - event belongs to this host group. <> - event does not belong to this host group. |
Host template | = <> |
Specify a host template or a template to exclude. = - event belongs to a trigger inherited from this host template. <> - event does not belong to a trigger inherited from this host template. |
Host | = <> |
Specify a host or a host to exclude. = - event belongs to this host. <> - event does not belong to this host. |
Trigger | = <> |
Specify a trigger or a trigger to exclude. = - event is generated by this trigger. <> - event is generated by any other trigger, except this one. |
Trigger name | like not like |
Specify a string in the trigger name or a string to exclude. like - event is generated by a trigger, containing this string in the name. Case sensitive. not like - this string cannot be found in the trigger name. Case sensitive. Note: Entered value will be compared to trigger name with all macros expanded. |
Trigger severity | = <> >= <= |
Specify trigger severity. = - equal to trigger severity <> - not equal to trigger severity >= - more or equal to trigger severity <= - less or equal to trigger severity |
Trigger value | = | Specify a trigger value. = - equal to trigger value (OK or PROBLEM) |
Time period | in not in |
Specify a time period or a time period to exclude. in - event time is within the time period. not in - event time is not within the time period. See Time period specification page for description of the format. |
Maintenance status | in not in |
Specify a host in maintenance or not in maintenance. in - host is in maintenance mode. not in - host is not in maintenance mode. Note: If several hosts are involved in the trigger expression, the condition matches if at least one of the hosts is/is not in maintenance mode. |
Trigger value:
When a new action for triggers is created, it gets two automatic conditions (both can be removed by the user):
The following conditions can be set for discovery-based events:
Condition type | Supported operators | Description |
---|---|---|
Host IP | = <> |
Specify an IP address range or a range to exclude for a discovered host. = - host IP is in the range. <> - host IP is not in the range. |
Service type | = <> |
Specify a service type of a discovered service or a service type to exclude. = - matches the discovered service. <> - does not match the discovered service. |
Service port | = <> |
Specify a TCP port range of a discovered service or a range to exclude. = - service port is in the range. <> - service port is not in the range. |
Discovery rule | = <> |
Specify a discovery rule or a discovery rule to exclude. = - using this discovery rule. <> - using any other discovery rule, except this one. |
Discovery check | = <> |
Specify a discovery check or a discovery check to exclude. = - using this discovery check. <> - using any other discovery check, except this one. |
Discovery object | = | Specify the discovered object. = - equal to discovered object (a device or a service). |
Discovery status | = | Up - matches 'Host Up' and 'Service Up' events Down - matches 'Host Down' and 'Service Down' events Discovered - matches 'Host Discovered' and 'Service Discovered' events Lost - matches 'Host Lost' and 'Service Lost' events |
Uptime/Downtime | >= <= |
Uptime for 'Host Up' and 'Service Up' events. Downtime for 'Host Down' and 'Service Down' events. >= - is more or equal to. Parameter is given in seconds. <= - is less or equal to. Parameter is given in seconds. |
Received value | = <> >= <= like not like |
Specify the value received from an agent (Zabbix, SNMP). Case sensitive string comparison. If multiple Zabbix agent or SNMP checks are configured for a rule, received values for all of them are checked (each check generates a new event which is matched against all conditions). = - equal to the value. <> - not equal to the value. >= - more or equal to the value. <= - less or equal to the value. like - contains the substring. Parameter is given as a string. not like - does not contain the substring. Parameter is given as a string. |
Proxy | = <> |
Specify a proxy or a proxy to exclude. = - using this proxy. <> - using any other proxy except this one. |
Service checks in a discovery rule, which result in discovery events, do not take place simultaneously. Therefore, if multiple values are configured for Service type
, Service port
or Received value
conditions in the action, they will be compared to one discovery event at a time, but not to several events simultaneously. As a result, actions with multiple values for the same check types may not be executed correctly.
The following options of calculating conditions are available:
Note that "AND" calculation should not be used between several triggers when they are selected as a Trigger=
condition. Actions can only be executed based on the event of one trigger.
Host group = Oracle servers
Host group = MySQL servers
Trigger name like 'Database is down'
Trigger name like 'Database is unavailable'
is evaluated as
(Host group = Oracle servers or Host group = MySQL servers) and (Trigger name like 'Database is down' or Trigger name like 'Database is unavailable')
Since Zabbix 2.0.6 if a certain object (host, template, trigger, etc) used in an action condition/operation is deleted, the condition/operation is removed and the action is disabled to avoid incorrect execution of the action. The action can be re-enabled by the user.
This behavior takes place when deleting:
Before 2.0.6 the missing object was displayed as unknown and the condition remained in place.
Note: If a remote command has many target hosts, and we delete one of them, only this host will be removed from the target list, the operation itself will remain. But, if it's the only host, the operation will be removed, too. The same goes for "link to template" and "unlink from template" operations.
Actions are not disabled when deleting a user or user group used in a "send message" operation.