Ad Widget

Collapse

Zabbix and fping (ICMP Monitoring)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • zayed2020
    Junior Member
    • Aug 2020
    • 5

    #1

    Zabbix and fping (ICMP Monitoring)

    I need some guidance on ICMP monitoring with zabbix.
    This is my setup:
    - zabbix-server
    - host1
    - host2

    I've added host1 to zabbix-server. Now i want to monitor via 'simple checks' icmp from host1 to host2. so basicially i want to create an item in host1 (using Zabbix UI) and want to ping host2 and see it's responses (like alive/dead, ping loss % and ping response time) using the simple check option.

    I understand that I need fping for that. But here's the confusion:
    Where do i need fping installed? Zabbix server ONLY or in host1 too (since i want to ping host2 from host1 and get data in zabbix server)?

    Reference I've used was from https://www.zabbix.com/documentation...cks#icmp_pings.

    I've installed fping in host1 (running centos7) and it's binary location is at /usr/local/sbin/fping. I've set the 'FpingLocation' in zabbix server conf file to '/usr/local/sbin/fping' instead of default /usr/sbin/fping. (checked from https://www.zabbix.com/documentation.../zabbix_server).

    But I'm getting error in items page of host1 that item is not support and says error in logs and in item page:
    At least one of '/usr/local/sbin/fping', '/usr/sbin/fping6' must exist. Both are missing in the system.


    Please suggest the approach here. What am i doing wrong? The documentation isn't clear also. I've also set the setuid/setgid for root:zabbix user/group as per documentation.

    Can anyone please suggest the correct approach? My end goal is this:
    1. monitor host1, host2, host3...host10 from zabbix server using simple checks icmp
    2. monitor other hosts from each host.
    i.e. host1 will ping host2-host10
    host2 will ping host1-host10 except iteself
    host3 will ping host1-host10 except iteself
    and so on

    Thanks in advance.
  • isaqueprofeta
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Aug 2020
    • 154

    #2
    Are you sure that zabbix user has permission to use that binnary? sbin is commonly a directory that only root has access. Look out for that. maybe search out for setfacl to easy the permission access.

    Comment

    • zayed2020
      Junior Member
      • Aug 2020
      • 5

      #3
      Yes, zabbix 'group' has access to the binary. I've followed the commands given in https://www.zabbix.com/documentation...cks#icmp_pings to set necessary permissions. Is my approach ok in order to achieve the end result (i.e. ping other hosts from another host)? I'm unable to get these working:

      icmpping
      icmppingloss
      icmppingsec

      Someone please advise the correct way to do this. Thanks in advance.

      Comment

      • isaqueprofeta
        Senior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • Aug 2020
        • 154

        #4
        Ouch sorry for my misunderstanding, and, you can't do this with a monitored agent.

        What you need is probably a Zabbix Proxy, it will do the poolings/pings instead of server and send the result for the server (it uses it's own fping btw): https://www.zabbix.com/documentation...concepts/proxy

        Comment

        • zayed2020
          Junior Member
          • Aug 2020
          • 5

          #5
          OK...let me check again then. Thanks splitek & isaqueprofeta .
          So, can you answer these please:
          1. i should uninstall fping from all hosts i've installed in?
          2. how do i achieve this operation: ping from host1 to host2-9 and get data stored in zabbix server. what's the purpose of 'target' field in icmp key then if i can't use another host to 'ping' from? kindly help me to clarify please.
          3. i can only ping to other hosts using zabbix server or zabbix proxy? so if i have host1-host10 in network1 and zabbix in network2, and i want to monitor connection of host1-10, i should put a proxy in network1 and ping from there to host1-10 and forward it to zabbix server and get the view?

          Thanks in advance.

          Comment

          • zayed2020
            Junior Member
            • Aug 2020
            • 5

            #6
            Please help to answer the followings:
            1. i should uninstall fping from all hosts i've installed in?
            2. how do i achieve this operation: ping from host1 to host2-9 and get data stored in zabbix server. what's the purpose of 'target' field in icmp key then if i can't use another host to 'ping' from? kindly help me to clarify please.
            3. i can only ping to other hosts using zabbix server or zabbix proxy? so if i have host1-host10 in network1 and zabbix in network2, and i want to monitor connection of host1-10, i should put a proxy in network1 and ping from there to host1-10 and forward it to zabbix server and get the view?

            Thanks in advance.

            Comment

            • isaqueprofeta
              Senior Member
              Zabbix Certified SpecialistZabbix Certified Professional
              • Aug 2020
              • 154

              #7
              Do yourself a favor and please, watch this video: https://www.youtube.com/watch?v=H1ny3o6xlTE

              Your answers:

              1. i should uninstall fping from all hosts i've installed in?
              Yes, with the exception of the host that'll gonna act like a proxy (this is your host1)

              2. how do i achieve this operation: ping from host1 to host2-9 and get data stored in zabbix server. what's the purpose of 'target' field in icmp key then if i can't use another host to 'ping' from? kindly help me to clarify please.
              Install zabbix-proxy in host1 and configure it to work with your zabbix-server and it's going to act as an extended arm (It only gets data/preprocess it and send to zabbix-server) of the server as I've said before.

              3. i can only ping to other hosts using zabbix server or zabbix proxy? so if i have host1-host10 in network1 and zabbix in network2, and i want to monitor connection of host1-10, i should put a proxy in network1 and ping from there to host1-10 and forward it to zabbix server and get the view?
              That's exactly the meaning of zabbix-proxy existence.

              Comment

              • zayed2020
                Junior Member
                • Aug 2020
                • 5

                #8
                Thank you very much for clarifying all the confusions.I will do as you suggest isaqueprofeta .

                Comment

                Working...