[ZBX-19999] Zabbix Agent 2 - Unknown metric systemd.service.active_state Created: 2021 Sep 21  Updated: 2022 Nov 17  Resolved: 2022 Nov 17

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Documentation (D)
Affects Version/s: 5.0.15, 5.4.4
Fix Version/s: None

Type: Problem report Priority: Major
Reporter: Felix Ubiera Assignee: Edgar Akhmetshin
Resolution: Won't fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Based on the documentation there's no required configuration to use the systemd template, but even though the "systemd.unit.info" command is working, there are others that are not. Can you please help me?

 

I am using Zabbix server 5.4.4 and agent v2 5.4.4

Documentation that I used:

Zabbix agent 2 template operation [Zabbix Documentation 5.4]

Browse Zabbix / Zabbix - ZABBIX GIT

Steps to reproduce:

  1. Configure agent with server IP and hostname only
  2. Start zabbix agent2 service and enabled.
  3. run zabbix get from server: zabbix_get -s <zabbix_agent_ip> -k 'systemd.service.active_state[httpd.service]'

Result:

Error from the command:
ZBX_NOTSUPPORTED: Unknown metric systemd.service.active_state

Error in logfile from zabbix agent2:

2021/09/21 15:50:26.070186 received passive check request: 'systemd.service.active_state[httpd.service]' from 'x.x.x.x'
2021/09/21 15:50:26.070310 [1] processing update request (1 requests)
2021/09/21 15:50:26.070332 [1] cannot monitor metric "systemd.service.active_state[httpd.service]": Unknown metric systemd.service.active_state
2021/09/21 15:50:26.070347 sending passive check response: ZBX_NOTSUPPORTED: 'Unknown metric systemd.service.active_state' to 'x.x.x.x'

Expected:



 Comments   
Comment by Edgar Akhmetshin [ 2022 Nov 17 ]

https://git.zabbix.com/projects/ZBX/repos/zabbix/browse/templates/app/systemd/template_app_systemd.yaml?at=release%2F5.4

              type: DEPENDENT
              key: 'systemd.service.active_state["{#UNIT.NAME}"]'

Please be advised that this section of the tracker is for bug reports only. The case you have submitted can not be qualified as one, so please reach out to [email protected] for commercial support (https://zabbix.com/support) or consultancy services. Alternatively, you can also use our IRC channel or community forum (https://www.zabbix.com/forum) for assistance. With that said, we are closing this ticket. Thank you for understanding.

Generated at Sat Aug 02 10:50:43 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.