Zabbix: Fixing Active Checks to Work With Zabbix Proxy

We've recently changed our Zabbix 1.8.1 setup to include Zabbix Proxy, which broke all our active checks (f.ex. monitoring of log files). The solution seems to be having the proxy first, before the Zabbix Server, in the Zabbix Agent's config parameter Server, i.e. "Server=<proxy ip>,<server ip>".

After the introduction of the proxy, retrieval of active checks by the agent started to fail:

2977:20120803:142521.844 zabbix_agentd started. Zabbix 1.8.1 (revision 9702).
2984:20120803:142521.850 zabbix_agentd active check started []
2984:20120803:142522.028 No active checks on server: host [] not found

I know that this happens if the name of the host in the Zabbix Server UI differs from the Hostname in /etc/zabbix/zabbix_agentd.conf ( in this case) and indeed there was a difference - the name was shown as "" ( is the hostname of the new Zabbix Proxy).

However it wasn't possible to change the name, when clicking on it (Configuration -> Hosts -> find the host -> click its name) to edit it, the proxy prefix there isn't editable. I tried to change Hostname in zabbix_agentd.conf to  "" but to no avail.

Finally I tried to switch the order of the server and proxy IPs in the Server param so that the proxy is first and thus the agent retrieves its active checks from the proxy instead of from the server, which fixed the problem.

From /var/log/zabbix-agent/zabbix_agentd.log after the change (and DebugLevel=4 as the default level of 3 only showed "active check started []" followed by "collector started" but no details of the checks):

25382:20120808:145557.663 refresh_active_checks('',10051)
25382:20120808:145557.664 Sending [{
  "request":"active checks",
25382:20120808:145557.664 Before read
25382:20120808:145557.669 Got [{

Tags: monitoring DevOps

Copyright © 2024 Jakub Holý
Powered by Cryogen
Theme by KingMob