adubkov/py-zabbix

Autodetection of servers is wrong

potchin opened this issue · 0 comments

The code that determines which server to send a metric to (_load_from_config) queries the "Server" and "Port" sections of the zabbix config. It should query the "ServerActive" parameter, in fact the "Port" parameter is not valid and zabbix will not start if its present...

Starting Zabbix agent: zabbix_agentd [21739]: unknown parameter [Port] in config file [/etc/zabbix/zabbix_agentd.conf], line 88

From the config..

Option: ServerActive
List of comma delimited IP:port (or hostname:port) pairs of Zabbix servers for active checks.
If port is not specified, default port is used.
IPv6 addresses must be enclosed in square brackets if port for that host is specified.
If port is not specified, square brackets for IPv6 addresses are optional.
If this parameter is not specified, active checks are disabled.
Example: ServerActive=127.0.0.1:20051,zabbix.domain,[::1]:30051,::1,[12fc::1]