Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Installing zabbix-agent on pfsense 2.0.2

    Problems Installing or Upgrading pfSense Software
    2
    4
    18.4k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      malayo
      last edited by

      once logged in to shell on pfsense, i ran below commad succesfully (after enabled WAN interface)

      pkg_add -r http://ftp.nl.freebsd.org/pub/FreeBSD/ports/packages/All/zabbix-agent-1.8.13,2.tbz

      but I could not find rc.local.conf to enable autostart of zabbix-agentd

      cd /usr/local/sbin/
      ./zabbix-agentd start
      ./zabbix-agentd status

      does not give any output

      i'm able to telnet to port 10050 on pfsense though

      1 Reply Last reply Reply Quote 0
      • stephenw10S
        stephenw10 Netgate Administrator
        last edited by

        A number of things occur to me.

        pfSense 2.0.2 is built on FreeBSD 8.1, that ftp site appears to be for a far more recent release.
        You probably wanted to use:

        http://ftp-archive.freebsd.org/pub/FreeBSD-Archive/old-releases/i386/8.1-RELEASE/packages/All/zabbix-agent-1.8.2_2%2c2.tbz
        

        @malayo:

        does not give any output

        No output at all would be very surprising. I assume it actually gave some error, what was it?

        Steve

        1 Reply Last reply Reply Quote 0
        • M
          malayo
          last edited by

          after reboot and reconfigure config file to point to correct IP of zabbix server, i managed to telnet port 10050 but it quickly got disconnected as below

          # telnet 192.168.56.120 10050
          Trying 192.168.56.120...
          Connected to 192.168.56.120.
          Escape character is '^]'.
          Connection closed by foreign host.
          

          i added pfsense host with pfsense template but I can see is snmp shown in red "timeout connecting to [192.168.56.120:161]"

          running below from zabbix server gave output 0.000000

          zabbix_get -s 192.168.56.120 -p 10050 -k "system.cpu.load[all,avg1]"
          

          from my laptop (192.168.56.1)

          # snmpwalk -c Str1nG -v 2c 192.168.56.120 | head
          iso.3.6.1.2.1.1.1.0 = STRING: "pfSense.localdomain 4030001430 FreeBSD 8.1-RELEASE-p13"
          iso.3.6.1.2.1.1.2.0 = OID: iso.3.6.1.4.1.12325.1.1.2.1.1
          iso.3.6.1.2.1.1.3.0 = Timeticks: (372873) 1:02:08.73
          iso.3.6.1.2.1.1.4.0 = ""
          iso.3.6.1.2.1.1.5.0 = STRING: "pfSense.localdomain"
          iso.3.6.1.2.1.1.6.0 = ""
          iso.3.6.1.2.1.1.7.0 = INTEGER: 76
          iso.3.6.1.2.1.1.8.0 = Timeticks: (3) 0:00:00.03
          iso.3.6.1.2.1.1.9.1.2.1 = OID: iso.3.6.1.4.1.12325.1.1.1.10.2
          iso.3.6.1.2.1.1.9.1.2.2 = OID: iso.3.6.1.4.1.12325.1.1.1.10.3
          
          1 Reply Last reply Reply Quote 0
          • M
            malayo
            last edited by

            finally got server to show green on zabbix agent & snmp on status. Below are my configs

            pfsense zabbix_agentd.conf
            –--------------------------
            LogFile=/tmp/zabbix_agentd.log
            Server=192.168.56.101
            Hostname=router

            zabbix server

            Server=localhost,zabbix
            Hostname=Zabbix Server
            StartAgents=5
            DebugLevel=3
            PidFile=/var/run/zabbix-agent/zabbix_agentd.pid
            LogFile=/var/log/zabbix-agent/zabbix_agentd.log
            Timeout=3

            note:

            -i'm connecting trough IP, hence Hostname are based on host setting at zabbix interface
            -i add entry on /etc/hosts for zabbix hostname of zabbix server
            -templates used on pfsense host Template_SNMPv2_Device & Template_pfSense

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.