Ad Widget

Collapse

Zabbix Proxy (active) - "Unable to connect to the server" issue.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • gdvilela
    Junior Member
    • Sep 2018
    • 7

    #1

    Zabbix Proxy (active) - "Unable to connect to the server" issue.

    Hi, everyone!

    As the title says I'm having some issues with the communication between my Zabbix Server and Zabbix Proxy.
    I installed and configured the Zabbix Server in one machine with the IP 192.168.15.X and my Zabbix Proxy (with an Agent to monitor the status and such) in another machine with the IP 192.168.15.Y.
    The server works well but when it comes to the proxy, things went bad quite fast. The server and the agent can communicate without a problem but whenever I add the proxy in the middle, my server stops receiving the data.
    know in the proxy's configuration file we need to tell if our proxy will be passive or active (since the default is active I left it unchanged), point to our Zabbix Server (param Server in zabbix_proxy.conf) and give it a name (param HostName in zabbix_proxy.conf), which will be the same name we'll use on the GUI.
    After that I configured the Zabbix Agent, which is in the same machine as the Zabbix Proxy, informing which IP's it will accept requests and giving it a name.

    After all of that, I enabled and started both (Agent and Proxy) but regardless of what I keep getting this message:
    Code:
     Unable to connect to the server [192.168.15.X]:10051 [cannot connect to [[192.168.15.X]:10051]: [113] No route to host]
    My configuration files:
    zabbix_proxy.conf
    Code:
    ProxyMode=0
    Server=192.168.15.X
    Hostname=zbxproxy
    DBName= /tmp/zabbix (using SQLite3)
    zabbix_agentd.conf
    Code:
    Server=127.0.0.1, 192.168.15.X, 192.168.15.Y (my proxy's IP)
    Hostname=zbxagent
    And yes, I've added both the proxy (active mode) and the agent (host) in my interface and I'm still using ports 10050 and 10051.

    I've read it could've been an issue with Selinux and such has already been disabled manually (/etc/sysconfig/selinux) but still no sucess.

    Currently using Zabbix 3.4 on CentOS 7 with SQLite 3.

    Any help is grately appreciated!
    Last edited by gdvilela; 07-10-2018, 21:05. Reason: zabbix proxy
  • gdvilela
    Junior Member
    • Sep 2018
    • 7

    #2
    After a friend pointed about the firewall, I realized SELinux is not a firewall and I also remembered the fact I forgot to configure the firewall in my Zabbix Server machine, after that things started to work properly!
    Commands for such:
    Code:
    firewall-cmd --permanent --add-port=10050/tcp
    firewall-cmd --permanent --add-port=10051/tcp
    firewall-cmd --permanent --add-port=80/tcp
    firewall-cmd --reload
    systemctl restart firewalld

    Comment

    Working...