We are not seeing IPv6 addresses being discovered on Juniper devices in our implementation. We do see IPv6 addresses for Cisco devices being discovered correctly. Both Juniper and Cisco have their IPv4 addresses discovered correctly.
My PHP is bad, but I went through the code and think the issue may be with how Juniper responds to the snmp_get on line 51 of ‘include/discovery/ipv6-addresses.inc.php’.
For Cisco devices, the response looks like this:
user@tools-server-01:/opt/librenms/includes/discovery$ snmpwalk -v2c -c XXXXX ip.of.cisco.device -m IP-MIB .1.3.6.1.2.1.4.34.1.5.2.16
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f0:0a:00:00:00:00:00:00:00:02” = OID: IP-MIB::ipAddressPrefixOrigin.64.ipv6.“20:01:05:06:01:00:f0:0a:00:00:00:00:00:00:00:00”.126
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f0:0d:00:00:00:00:00:00:00:11” = OID: IP-MIB::ipAddressPrefixOrigin.1081.ipv6.“20:01:05:06:01:00:f0:0d:00:00:00:00:00:00:00:10”.127
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:00:00:00:00:00:01:94:00:02” = OID: IP-MIB::ipAddressPrefixOrigin.5.ipv6.“20:01:05:06:01:00:f4:00:00:00:00:00:01:94:00:02”.128
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:02” = OID: IP-MIB::ipAddressPrefixOrigin.8.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:00”.126
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:1d” = OID: IP-MIB::ipAddressPrefixOrigin.9.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:1c”.126
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:21” = OID: IP-MIB::ipAddressPrefixOrigin.10.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:20”.126
On Juniper, it returns this:
user@tools-server-01:/opt/librenms/includes/discovery$ snmpwalk -v2c -c XXXXX ip.of.juniper.device -m IP-MIB .1.3.6.1.2.1.4.34.1.5.2.16
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:00:00:00:00:00:01:94:00:03” = OID: SNMPv2-SMI::zeroDotZero
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:32” = OID: SNMPv2-SMI::zeroDotZero
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:3a” = OID: SNMPv2-SMI::zeroDotZero
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:46” = OID: SNMPv2-SMI::zeroDotZero
IP-MIB::ipAddressPrefix.ipv6.“20:01:05:06:01:00:f4:01:00:00:00:00:00:00:00:79” = OID: SNMPv2-SMI::zeroDotZero
Here’s the requested information from our system:::
user@tools-server-01:/opt/librenms$ s ./validate.php
[sudo] password for user:
Component | Version |
---|---|
LibreNMS | 1.51-55-ge599487 |
DB Schema | 2019_02_10_220000_add_dates_to_fdb (132) |
PHP | 7.3.2-3+ubuntu16.04.1+deb.sury.org+1 |
MySQL | 10.0.38-MariaDB-0ubuntu0.16.04.1 |
RRDTool | 1.5.5 |
SNMP | NET-SNMP 5.7.3 |
====================================
[OK] Composer Version: 1.8.5
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct
discovery.php pastebin - https://p.libren.ms/view/4379e808
poller.php pastebin - //p.libren.ms/view/7d9f7938
Please let me know if this is an issue with our implementation or if it’s a code issue. Thx