Ad Widget

Collapse

Host with 2 interfaces

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • TheBonaZabbix
    Member
    • Feb 2023
    • 67

    #1

    Host with 2 interfaces

    Dear all,
    I've an host with 2 interfaces
    Click image for larger version

Name:	image.png
Views:	2736
Size:	38.9 KB
ID:	460190

    how can i refer to the interfaces ?
    HOST.CONN works (it is converted to the IP of the SNMP interface)
    I was hoping HOST.CONN2 would convert to the other IP but not.

    Anyone have a suggestion please?
    I've been searching the internet all day but can't find anything about it.

    Thank you

    Andrea​
  • Hamardaban
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • May 2019
    • 2713

    #2
    Before searching the Internet, you need to look in the documentation.
    Take a close look at the list of macros and pay attention to the «Supported in» and footnotes.

    https://www.zabbix.com/documentation...ed_by_location
    Last edited by Hamardaban; 28-02-2023, 19:16.

    Comment

    • TheBonaZabbix
      Member
      • Feb 2023
      • 67

      #3
      Hi,
      I have read the documentation but it is not clear to me, sorry !

      I try to show my configuration.
      These are the item associated to the host​



      I would like to add a widget to the dashboard that summarizes the status of the pings (for each interface) , like this
      Click image for larger version

Name:	image.png
Views:	2695
Size:	6.3 KB
ID:	460226

      How can refer to the Host Agent interface (with IP​ 10.3.XX) ?

      Many many thanks !
      Have a good day
      Andrea

      Comment

      • Semiadmin
        Senior Member
        • Oct 2014
        • 1625

        #4
        Just create an prototype for ping test in internal LLD rule via zabbix[host,discovery,interfaces]

        Comment

        • TheBonaZabbix
          Member
          • Feb 2023
          • 67

          #5
          I give up.
          It is too complicated.
          I do not understand anything.
          Why discovery ? I already know what are the IPs for each host.​

          Thanks
          Ciao

          Comment

          • cyber
            Senior Member
            Zabbix Certified SpecialistZabbix Certified Professional
            • Dec 2006
            • 4807

            #6
            Why discovery? Then you can have ping towards all interfaces...
            Currently you seem to have ping only towards that SNMP interface IP...

            Comment

            • TheBonaZabbix
              Member
              • Feb 2023
              • 67

              #7
              Dear,
              I'm sorry but I'm very confused.

              I've created this Discovery rule for my host
              Click image for larger version

Name:	image.png
Views:	2817
Size:	36.2 KB
ID:	460252
              The TEST returns
              Click image for larger version

Name:	image.png
Views:	2799
Size:	43.4 KB
ID:	460253
              ​....and now ?

              What other operations/configuration are missing?
              How can use these results ?

              Thanks for your precious help
              ​​

              Comment

              • TheBonaZabbix
                Member
                • Feb 2023
                • 67

                #8
                Originally posted by Semiadmin
                Just create an prototype for ping test in internal LLD rule via zabbix[host,discovery,interfaces]
                Dear,
                can you give me some additional information?
                I would be really grateful.
                I can't figure it out either with the documentation or with my internet searches.
                Please.

                Thank you​

                Comment

                • cyber
                  Senior Member
                  Zabbix Certified SpecialistZabbix Certified Professional
                  • Dec 2006
                  • 4807

                  #9
                  Now add item prototypes...

                  Comment

                  • TheBonaZabbix
                    Member
                    • Feb 2023
                    • 67

                    #10
                    Thanks but the doc is incomprehensible for my little brian.

                    This is my Discovery rule (type Zabbix internal)
                    Click image for larger version

Name:	image.png
Views:	2821
Size:	28.2 KB
ID:	460288
                    I've to add Item Prototypes ?
                    How ?
                    Click image for larger version

Name:	image.png
Views:	2794
Size:	36.5 KB
ID:	460289
                    Which Type ? Zabbix Internal ?
                    And the key ?

                    I can't figure out if I'm stupid or what I'm trying to do is difficult.

                    Comment

                    • TheBonaZabbix
                      Member
                      • Feb 2023
                      • 67

                      #11
                      Hi all.
                      Could anyone help me on how to configure the ITEM prototype ?
                      An example would be great.
                      Sorry if I insist but really, I've been spending several hours on the Internet without finding a clear example.

                      My scenario is simple:
                      I have a host (router) with two network interfaces.
                      One (public) interface supports SNMP queries (so on this interface I have to do the classic ping plus some SNMP queries)
                      On the other (private) interface, pinging is sufficient
                      If the public is not responding the status for the host should be ERROR
                      If the private does not respond (but the public responds) the status for the host should be WARNING.

                      That's all.

                      I am going crazy.
                      The documentation doesn't help me
                      Thank you all for the help and I apologize again for my insistence.​

                      Comment

                      • cyber
                        Senior Member
                        Zabbix Certified SpecialistZabbix Certified Professional
                        • Dec 2006
                        • 4807

                        #12
                        Name: Interface[{#IF.IP}]
                        Type. simple check
                        key: icmpping[{#IF.IP}]

                        Rest of it you should be able to figure out... like data type (integer) and polling interval...​

                        Comment

                        • TheBonaZabbix
                          Member
                          • Feb 2023
                          • 67

                          #13
                          Cyber, many thanks for you help.
                          I'll test it as soon as I have time and let you know.
                          Thank you !!!​

                          Comment

                          • TheBonaZabbix
                            Member
                            • Feb 2023
                            • 67

                            #14
                            Dear Cyber,
                            with your help I can discover the interfaces. Many thanks.
                            ​​
                            Last question...
                            I'm trying to add in a dashboard a widget that contains each IP, like this


                            The text {HOST.IP1} or {HOST.IP2} are not converted in the value (IP address) discovered.
                            How can refer to these discovery values ?

                            Many thanks
                            Have a good week
                            Andrea​

                            Comment

                            • db100
                              Member
                              • Feb 2023
                              • 61

                              #15
                              is it possible to define 2 interfaces of the same type for high-availability?

                              in particular defining 2 agent interfaces onto 2 different hosts, and so zabbix server will choose the default interface if available, otherwise switch onto the second one. is this possible to achieve somehow ?

                              Comment

                              Working...