description: 'Encodes the install state of the unit file of FragmentPath. It currently knows the following states: "enabled", "enabled-runtime", "linked", "linked-runtime", "masked", "masked-runtime", "static", "disabled", and "invalid".'
- uuid: a571c0d144b14fd4a87a9d9b2aa9fcd6
name: Templates/Applications
- uuid: 90ac276995294a6aa88462c032d2ddaf
template: 'Systemd by Zabbix agent 2'
name: 'Systemd by Zabbix agent 2'
Get systemd units metrics from plugin for the zabbix-agent2.
1. Setup and configure zabbix-agent2 compiled with the Systemd monitoring plugin.
2. Set filters with macros if you want to override default filter parameters.
You can discuss this template or leave feedback on our forum https://www.zabbix.com/forum/zabbix-suggestions-and-feedback/
Generated by official Zabbix template tool "Templator"
- name: Templates/Applications
- uuid: 0dfbc5994c1e44a6a1a2aa8ecc2f0347
name: 'Service units discovery'
key: 'systemd.unit.discovery[service]'
- macro: '{#UNIT.ACTIVESTATE}'
value: '{$SYSTEMD.ACTIVESTATE.SERVICE.MATCHES}'
- macro: '{#UNIT.ACTIVESTATE}'
value: '{$SYSTEMD.ACTIVESTATE.SERVICE.NOT_MATCHES}'
operator: NOT_MATCHES_REGEX
value: '{$SYSTEMD.NAME.SERVICE.MATCHES}'
value: '{$SYSTEMD.NAME.SERVICE.NOT_MATCHES}'
operator: NOT_MATCHES_REGEX
- macro: '{#UNIT.UNITFILESTATE}'
value: '{$SYSTEMD.UNITFILESTATE.SERVICE.MATCHES}'
- macro: '{#UNIT.UNITFILESTATE}'
value: '{$SYSTEMD.UNITFILESTATE.SERVICE.NOT_MATCHES}'
operator: NOT_MATCHES_REGEX
description: 'Discover systemd service units and their details.'
- uuid: 78587e9b16b5431bbccd2855998171fa
name: '{#UNIT.NAME}: Active state'
key: 'systemd.service.active_state["{#UNIT.NAME}"]'
description: 'State value that reflects whether the unit is currently active or not. The following states are currently defined: "active", "reloading", "inactive", "failed", "activating", and "deactivating".'
name: 'Unit Active State'
- type: DISCARD_UNCHANGED_HEARTBEAT
key: 'systemd.unit.get["{#UNIT.NAME}"]'
- uuid: 5237bd423307449b8a58f692082d2a0a
expression: 'last(/Systemd by Zabbix agent 2/systemd.service.active_state["{#UNIT.NAME}"])<>1'
name: '{#UNIT.NAME}: Service is not running'
- uuid: bed610e6ce33494b817eb787e34e18c2
name: '{#UNIT.NAME}: Load state'
key: 'systemd.service.load_state["{#UNIT.NAME}"]'
description: 'State value that reflects whether the configuration file of this unit has been loaded. The following states are currently defined: "loaded", "error", and "masked".'