zabbix代理尝试与服务器通话

问题描述:

我想创建一个zabbix代理和一个zabbix代理,并设置代理通过代理进行通话。我为此创建了docker容器(zabbix-proxy和zabbix-agent)。zabbix代理尝试与服务器通话

proxy.conf:

Server=192.10.30.58 # address of server 
ServerPort=10051 
Hostname=DFS 

agent.conf:

Server=ZabbixProxy # the zabbix-proxy container name 
ListenPort=10050 
Hostname=Agent 

我已经创建了也ZABBIX:

名为DFS代理。

名为DFS的宿主和192.10.30.3:10051

命名代理和192.18.0.4:10050(其中运行代理的内部IP)

我可以从监控 - 看到数据的主机>代理和代理的最新数据。

所以,它的工作。

但是,在我的日志,我可以看到,对于代理它给了我:

INFO success: zabbix-agentd entered RUNNIG state, process has stayed up for > than 1 seconds (startsecs) 


failed to accept an incoming connection: connection from "192.10.30.58" rejected, allowed hosts: "ZabbixProxy" 

(该192.10.30.3:10051是代理的外部IP)

看来,代理试图与服务器交谈,但我不知道为什么。

如果在agent.conf而不是ZabbixProxy(zabbix代理容器的名称)我把代理地址192.10.30.3,然后我仍然有相同的错误,我也无法获得代理的最新数据。


我我用ServerActive=ZabbixProxyServerActive=192.10.30.3:10051,我收到:

... 
INFO spawned: 'zabbix-agentd' with pid 51 
2017-04-12 16:37:55,916 INFO exited: zabbix-agentd (exit status 1; not expected) 
2017-04-12 16:37:57,928 INFO spawned: 'zabbix-agentd' with pid 52 
2017-04-12 16:37:57,988 INFO exited: zabbix-agentd (exit status 1; not expected) 
2017-04-12 16:38:01,001 INFO spawned: 'zabbix-agentd' with pid 53 
2017-04-12 16:38:01,061 INFO exited: zabbix-agentd (exit status 1; not expected) 
2017-04-12 16:38:02,063 INFO gave up: zabbix-agentd entered FATAL state, too many start retries too quickly 

当然,现在的代理不会在所有的工作。

参数Server适用于被动项目 - 到代理的传入连接。代理根据参数ServerActive连接到服务器(或代理),在您的情况下似乎配置错​​误。

+0

嗨,我现在有点困惑。所以,Agent只使用ServerActive?无论如何,我更新了我的帖子。它根本不起作用。我错过了什么?谢谢。 – George

+0

嗯,它似乎需要添加服务器的IP地址,不仅将zabbix代理IP放入服务器字段! – George

+0

不,您应该只有服务器或“ServerActive”中列出的代理。代理无法启动似乎是一个奇怪的问题 - 您应该尝试手动启动它并查看错误消息是什么。 – Richlv