Use MAC of device if no name is defined in Unifi device discovery

tags/zabbix-agent-addons-0.2.128-1
Daniel Berteaud 4 years ago
parent 78a6b1a2e4
commit 53b83f2d0e
  1. 2
      zabbix_scripts/disco_unifi

@ -80,7 +80,7 @@ if ($what eq 'devices'){
'{#UNIFI_DEV_ID}' => $entry->{device_id}, '{#UNIFI_DEV_ID}' => $entry->{device_id},
'{#UNIFI_DEV_ADOPTED}' => $entry->{adopted}, '{#UNIFI_DEV_ADOPTED}' => $entry->{adopted},
'{#UNIFI_DEV_MODEL}' => $entry->{model}, '{#UNIFI_DEV_MODEL}' => $entry->{model},
'{#UNIFI_DEV_NAME}' => $entry->{name}, '{#UNIFI_DEV_NAME}' => $entry->{name} || $entry->{mac},
'{#UNIFI_DEV_MAC}' => $entry->{mac}, '{#UNIFI_DEV_MAC}' => $entry->{mac},
'{#UNIFI_DEV_TYPE}' => $entry->{type} '{#UNIFI_DEV_TYPE}' => $entry->{type}
}; };

Loading…
Cancel
Save