Ad Widget

Collapse

ICMP Ping - any way to define the emitting interface?

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • mumblesheep
    Junior Member
    • Oct 2025
    • 2

    #1

    ICMP Ping - any way to define the emitting interface?

    Hello Zabbixers,

    I have three ethernet interfaces on my RaspberryPi - one connected to internal network, one to ISP A and one to ISP B.
    I wrote a ping script myself but it is getting unwieldy now that I am starting to monitor more internal systems and I fancy leaving the difficult bits to Zabbix in future :0)

    Alas... any internet search for "ping interface" finds many posts about the target host interface definitions. Is there a way to bend a template so that for each Ping I can decide which local interface the PICMP request should go out on?

    Many thanks!
    Mumblesheep
  • Answer selected by mumblesheep at 07-10-2025, 11:02.
    troffasky
    Senior Member
    • Jul 2008
    • 567

    Zabbix uses fping, which has a -I parameter, but this is not exposed:



    So you would have to write your own item.



    which would take the interface name as a parameter in addition. Should be pretty straightforward.

    Comment


    • mumblesheep
      mumblesheep commented
      Editing a comment
      Thank you - I will walk that path to knowledge!
  • troffasky
    Senior Member
    • Jul 2008
    • 567

    #2
    Zabbix uses fping, which has a -I parameter, but this is not exposed:



    So you would have to write your own item.



    which would take the interface name as a parameter in addition. Should be pretty straightforward.

    Comment


    • mumblesheep
      mumblesheep commented
      Editing a comment
      Thank you - I will walk that path to knowledge!
  • Donkey
    Junior Member
    • Jun 2024
    • 15

    #3
    What are you trying to achieve?

    Comment

    • troffasky
      Senior Member
      • Jul 2008
      • 567

      #4
      They want to monitor specific destinations via a specific interface. And maybe even the same destination over multiple paths, to compare latency/packet loss/etc.
      Last edited by troffasky; 07-10-2025, 13:02.

      Comment

      • mumblesheep
        Junior Member
        • Oct 2025
        • 2

        #5
        Originally posted by troffasky
        He wants to ...
        Who said this sheep was male? :P But you got me, I am :0)

        monitor specific destinations via a specific interface. And maybe even the same destination over multiple paths, to compare latency/packet loss/etc.
        - in the words of Detritus: "dat's der bunny!"

        Comment

        Working...