Zabbix proxy - Received empty response from Zabbix Agent

Mukul Jain picture Mukul Jain · Jun 24, 2015 · Viewed 22.4k times · Source

I am trying to setup zabbix proxy. My network is as below

Zabbix server IP: 192.168.101.11 (internal network) Zabbix proxy server: 192.168.102.109 (internal network) Zabbix agent: 172.1.16.2 (outside network but pingable from 102.109)

I can ping the zabbix agent IP from my proxy machine.

[root@102_109 ~]# ping 172.1.16.2
PING 172.1.16.2 (172.1.16.2) 56(84) bytes of data.
64 bytes from 172.1.16.2: icmp_seq=1 ttl=64 time=215 ms
64 bytes from 172.1.16.2: icmp_seq=2 ttl=64 time=214 ms
64 bytes from 172.1.16.2: icmp_seq=3 ttl=64 time=214 ms
64 bytes from 172.1.16.2: icmp_seq=4 ttl=64 time=214 ms

I can connect to the zabbix proxy from my zabbix server -

zabbix_get -k agent.ping -s 192.168.102.109
1

My zabbix_proxy.conf file (on 102.109) is as below

ProxyMode=0
Server=192.168.101.11
Hostname=CME_Proxy
LogFile=/tmp/zabbix_proxy.log
DBName=zabbix
DBUser=root
DBPassword=password

And on the zabbix agent machine (172.1.16.2) the configuration is as below.

EnableRemoteCommands=1
LogFile=/tmp/zabbix_agentd.log
Server=192.168.101.11,192.168.102.109
ServerActive=192.168.101.11,192.168.102.109
Hostname=172.1.16.2
AllowRoot=1

On my zabbix front end, I have configured the host as monitored by proxy (CME_Proxy) and there is only 1 item (agent.ping).

I am not able to get any data from the zabbix agent. From my proxy machine, when I run the following command, it returns a blank value.

zabbix_get -k agent.ping -s 172.1.16.2
<this is blank response>

Due to this, in the host configuration, zabbix shows error -

"Received empty response from Zabbix Agent at [172.1.16.2]. Assuming that agent dropped connection because of access permissions."

Can someone please guide me if the way I have configured is correct? If not how to do this correctly. If you need additional data please let me know.

Thank you

Mukul

Answer

Mukul Jain picture Mukul Jain · Jun 24, 2015

Figured it out:

In the agent config file, the following parameters

Server=192.168.101.11,192.168.102.109
ServerActive=192.168.101.11,192.168.102.109 

should have been

Server=192.168.101.11,172.1.16.1
ServerActive=192.168.101.11,172.1.16.1