Ad Widget

Collapse

LLD host discovery - overwrite existing host information

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mako
    Junior Member
    • Feb 2022
    • 3

    #1

    LLD host discovery - overwrite existing host information

    Zabbix 7.0.9

    I have a discovery rule, that scans an OLT (PON) via snmp (walk[OID]) and for every "child" device found (ONT/CPE) create a new host via "Host prototype" with an inherited snmp interface of the OLT.
    Every new host has his own uniqe serialnumber (like a MAC-Adress) as hostname. That works fine.

    I set the discovery rule, to not delete or disable generated hosts. I do not want to lose any historical data from the ONT / CPE (Host prototype).

    Sometimes a device can move from on OLT to another OLT.

    Now, the new OLT with the same discovery rule sees the devices in his ont table and would like to create a new host (prototype).
    Cannot create host: host with the same name "xxxxhostnamexxx" already exists.
    Thats true. But I like to force overwrite/update the existing ont/cpe/device withe the new interface datas instead of creating a new one.

    I know, I could write a script, tha uses the API to do what I do now with the discovery rules, but first I like to ask, if somebody has an idea how to overwrite an existing host instead of creating a new one
  • rpi_dwillis77
    Junior Member
    • Jun 2023
    • 5

    #2
    Hello mako Did you ever figure this out? I'm having the same problem, though with a different template and host type. I have manually-added hosts that are VMs in my vCenter that I want the VMware FQDN discovery rule to "take over" when it discovers them and update/add on to the existing entry (since some of those hosts may have other templates linked , I want to keep those linked and also have the VMware discovery apply its own). But instead I get errors about hosts with those names already existing.

    I'm wondering, do I really have to fully delete the host and let the discovery re-create it? Is there no way to make a discovery "take control" of an existing host when its criteria matches?

    Comment

    Working...