Ad Widget

Collapse

Single machine with multiple IP's and Templates

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Tkom
    Junior Member
    • Jul 2013
    • 2

    #1

    Single machine with multiple IP's and Templates

    I'm trying to figure out how to setup a template to work with multiple IP's for a single machine so that I don't have to manually setup a couple hundred items and triggers.

    Brief rundown of my setup. Currently have approximately 170 machines all with multiple IP's that fall under different categories. Each setup is created the exact same way as far as machine interfaces go.

    e.g.

    Machine 1
    Agent Interface 1: 172.30.16.1
    Agent Interface 2: 172.30.16.2
    SNMP interface 1: 172.30.16.3


    In my template I'd like to be able to setup an item that would pull from the interface I specify.

    eg.
    Simple check icmpping on each interface by somehow specifying the correct interface in the item setup so that I'm able to monitor all interfaces individually on the same machine.


    Is there a way to use the standard syntax of:
    icmpping[<target>,<packets>,<interval>,<size>,<timeout>]

    and have an additional field or something such as:
    icmpping[<target>,<packets>,<interval>,<size>,<timeout><int erface>]

    Where <interface> can be say A1, A2, S1 and so on?


    This way I'd be able to create a template with items such as "Interface 1 status", "SNMP interface 1 status" automatically via the template and then would be able to easily create the associated triggers.


    Sorry for repeating myself a couple of times there, bad habit...
  • heaje
    Senior Member
    Zabbix Certified Specialist
    • Sep 2009
    • 325

    #2
    Unfortunately, what you are asking to do is not possible. If you really want to monitor each interface on the host, then you'll need to create multiple "hosts" in zabbix - one for each interface that you want to monitor.

    Comment

    • Harmen
      Junior Member
      • Mar 2015
      • 9

      #3
      I've been browsing the internet and this forum for a bit for exactly the same question.

      This post is from 2009, is there already a proper solution for this? (We're running Zabbix 2.4)

      Comment

      • kloczek
        Senior Member
        • Jun 2006
        • 1771

        #4
        Originally posted by heaje
        Unfortunately, what you are asking to do is not possible. If you really want to monitor each interface on the host, then you'll need to create multiple "hosts" in zabbix - one for each interface that you want to monitor.
        So try to open some host page with monitoring interfaces definition and quickly you will realize that you can do this.
        You can define multiple agent IPs. You can setup separated IP to access to SNMP metrics. If you have several similar hosts you can put monitoring of such hosts using common template.
        http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
        https://kloczek.wordpress.com/
        zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
        My zabbix templates https://github.com/kloczek/zabbix-templates

        Comment

        • Harmen
          Junior Member
          • Mar 2015
          • 9

          #5
          Yep, but I do not want to use SNMP for this. I want to specifically ping certain IP addresses on a host, next to the SNMP check.

          We use SNMP to gather the regular metrics from the host, but that gives no information about wether an IP on that host is reachable / allive and what it's response times are. (These are multi-homed hosts, servers, routers, switches, etc.)

          Comment

          • kloczek
            Senior Member
            • Jun 2006
            • 1771

            #6
            Originally posted by Harmen
            Yep, but I do not want to use SNMP for this. I want to specifically ping certain IP addresses on a host, next to the SNMP check.

            We use SNMP to gather the regular metrics from the host, but that gives no information about wether an IP on that host is reachable / allive and what it's response times are. (These are multi-homed hosts, servers, routers, switches, etc.)
            As long as you have similarities in group of host with the same set of interfaces (like frotend, backend, backup etc interfaces) you can put them in host interface and in your template used on such similar hosts you can use macros like {HOST.DNS<1-9>} to for example ping these interfaces (as <target> in icmpping[] parameters). On monitor over simple check (which is fired from zbx proxy/server it make sense.
            In case zabbix items or zabbix items (active) does not make any difference over which one physical interface you will be monitoring agent metrics.
            http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
            https://kloczek.wordpress.com/
            zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
            My zabbix templates https://github.com/kloczek/zabbix-templates

            Comment

            Working...