Schrödinger's device

I have a device that both exists and doesn’t at the same time. I can’t add it because it exists, I can’t remove it because it doesn’t.

Prior to this I had deleted the device as it had accreted 15000+ interfaces due to ipsec tunnel churn. Where do I need to go looking to find the remanent data that is stopping me from adding it back?

root@nms2:/opt/librenms# ./addhost.php 192.168.33.1
Already have host with this IP 192.168.33.1
root@nms2:/opt/librenms# ./delhost.php 192.168.33.1
Host doesn't exist!
root@nms2:/opt/librenms# ./addhost.php 192.168.33.1
Already have host with this IP 192.168.33.1
root@nms2:/opt/librenms#

The message isn’t that the device exists, it’s that a device already exists which also has that IP registered to it. If you force add (-f) the device it will be added without any checks iirc

Sadly that gives me the same error.

root@nms2:/opt/librenms# ./addhost.php -f 192.168.33.1
Already have host with this IP 192.168.33.1
root@nms2:/opt/librenms#

I’ve submitted a fix for this. https://github.com/librenms/librenms/pull/4738 Keep an eye on it, once merged you should be good to force add

I have run into this after adding 190 hosts. I searched all IPs using the web interface and I was not able to find them existing. I am running into this with two new devices. Any ideas?

Version db58fea - Mon Feb 27 2017 17:32:13 GMT-0500
DB Schema #171
Web Server nginx/1.10.0
PHP 7.0.15-0ubuntu0.16.04.2
MySQL 10.0.29-MariaDB-0ubuntu0.16.04.1
RRDtool 1.5.5

What’s the actual error?

Changed the names to protect the innocent.


librenms@librenms:~$ ping my.server.local
PING my.server.local (192.168.0.10) 56(84) bytes of data.
64 bytes from my.server.local (192.168.0.10): icmp_seq=1 ttl=61 time=0.379 ms
64 bytes from my.server.local (192.168.0.10): icmp_seq=2 ttl=61 time=0.450 ms
64 bytes from my.server.local (192.168.0.10): icmp_seq=3 ttl=61 time=0.524 ms
^C
— my.server.local ping statistics —
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 0.379/0.451/0.524/0.059 ms
librenms@librenms:~$ ./addhost.php my.server.local
Already have host my.server.local (Barracuda)
librenms@librenms:~$ ./delhost.php my.server.local
Host doesn’t exist!
librenms@librenms:~$

Here is some additional information that I can add. This is actually the 2nd Barracuda Spam firewall that I am adding. The first has been in place and working for a while now. After looking around I did try this command on both devices to help me verify that my accounts were correct and if I could get any additional information.


librenms@librenms:~$ snmpget -v3 -a MD5 -A ***** -l authPriv -u ***** -x AES -X ***** -OUsb -m SNMPv2-MIB -M /opt/librenms/mibs -t 30 my1.server.local sysObjectID.0
sysObjectID.0 = OID: enterprises.8072.3.2.10
librenms@librenms:~$ snmpget -v3 -a MD5 -A ***** -l authPriv -u ***** -x AES -X ***** -OUsb -m SNMPv2-MIB -M /opt/librenms/mibs -t 30 my2.server.local sysObjectID.0
sysObjectID.0 = OID: enterprises.8072.3.2.10
librenms@librenms:~$

That means you have a device with the sysName of Barracuda already. You can either just force add the device or set $config['allow_duplicate_sysName'] = true; in config.php but this takes effect for auto-discovery and you may end up with duplicates if you use it.

Okay, I have found issue below. Apparently, Barracuda never thought anyone would purchase more than one of their devices? I am reaching out to Barracuda to see what can be done.

SNMPv2-MIB::sysName.0 = STRING: Barracuda

lol :slight_smile:

Force add for now, simple way round it.