cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
6235
Views
10
Helpful
3
Replies

LLDP Remote Port Identification - SNMP

Raja Solaimalai
Level 1
Level 1

Hi Team,

 

I am trying to find the Remote device IP in LLDP protocol through SNMP, but I couldn't able to get remote device IP 

 

could you please some one help here.

 

Below the OID's i  have tried to match :

 

lldpRemPortDesc~1.0.8802.1.1.2.1.4.1.1.7
lldpRemSysName~1.0.8802.1.1.2.1.4.1.1.9

1.0.8802.1.1.2.1.3.7.1 - lldpLocPortEntry

1.0.8802.1.1.2.1.3.7.1.3 - lldpLocPortId

ldpRemoteSystemsData (1.0.8802.1.1.2.1.3)

lldpRemoteSystemsData (1.0.8802.1.1.2.1.4)

ipNetToMediaIfIndex -1.3.6.1.2.1.4.22.1.1

ipNetToMediaPhysAddress-1.3.6.1.2.1.4.22.1.2

ipNetToMediaNetAddress - 1.3.6.1.2.1.4.22.1.3

 

[root@CBTCNBIGDC1 ~]# snmpwalk -v 2c -c xlcom *.*.*.* 1.0.8802.1.1.2.1.4.1.1.5
iso.0.8802.1.1.2.1.4.1.1.5.0.21.4 = Hex-STRING: 9C 52 F8 4F FB 4E
iso.0.8802.1.1.2.1.4.1.1.5.0.22.1 = Hex-STRING: 40 B4 F0 B7 67 40
iso.0.8802.1.1.2.1.4.1.1.5.0.43.2 = Hex-STRING: 4C 77 6D A0 32 00
[root@CBTCNBIGDC1 ~]#


[root@CBTCNBIGDC1 ~]# snmpwalk -v 2c -c xlcom 202.*.*.1 1.3.6.1.2.1.4.22.1.2 | grep 65.5
IP-MIB::ipNetToMediaPhysAddress.487.*.*.*. = STRING: 40:b4:f0:b7:67:41
IP-MIB::ipNetToMediaPhysAddress.812.10.176.*.* = STRING: 4c:77:6d:a0:33:bf
IP-MIB::ipNetToMediaPhysAddress.812.*.*.* = STRING: 0:be:75:33:50:bf
IP-MIB::ipNetToMediaPhysAddress.1160.10.194.166.20 = STRING: a4:a1:c2:65:5d:41
IP-MIB::ipNetToMediaPhysAddress.1194.*.*.*. = STRING: 4c:77:6d:a0:33:bf
IP-MIB::ipNetToMediaPhysAddress.1194.10.*.*.51 = STRING: 0:be:75:33:50:bf
IP-MIB::ipNetToMediaPhysAddress.1208.10.*.*.20 = STRING: a4:a1:c2:65:5d:41
[root@CBTCNBIGDC1 ~]#


[root@CBTCNBIGDC1 ~]# snmpwalk -v 2c -c xlcom 202.152.246.71 1.3.6.1.2.1.4.22.1.2.487
IP-MIB::ipNetToMediaPhysAddress.487.10.*.*.1 = STRING: 0:0:5e:0:1:1
IP-MIB::ipNetToMediaPhysAddress.487.10.1.*.* = STRING: 40:b4:f0:bc:50:1
IP-MIB::ipNetToMediaPhysAddress.487.10.*.*.* = STRING: 40:b4:f0:b7:67:41
IP-MIB::ipNetToMediaPhysAddress.487.10.*.* = STRING: 4c:77:6d:a0:32:15
IP-MIB::ipNetToMediaPhysAddress.487.10.*.*.* = STRING: 0:be:75:33:4f:15

3 Replies 3

martin5641289
Level 1
Level 1

I can confirm that these OIDs do not show LLDP neighbor IP address as I checked it in our network. Command "show lldp neighbor" shows IP address of discovered device. I do not know why the IP could not be listed via SNMP while show command shows the IP. I am guessing the well known reason - "it is not a bug it is a feature".

Raja Solaimalai
Level 1
Level 1

Hi , This is not a bug. I have raised to find the LLDP neighbour remote device IP using SNMP .

 

Could you please help me out ?

martin5641289
Level 1
Level 1

I have found how it works. IP address is contained at received OID. Please check snmpwalk with numeric output. The "show lldp neighbor" command shows 192.168.85.1 in my case. And the same you can see in the OID output. Similar way is used for IPV6.

 

My results:

snmpwalk -v 2c -c XXX 10.22.33.141 1.0.8802.1.1.2.1.4.2 -On
.1.0.8802.1.1.2.1.4.2.1.3.0.36.1.1.4.192.168.85.1 = INTEGER: systemPortNumber(3)
.1.0.8802.1.1.2.1.4.2.1.4.0.36.1.1.4.192.168.85.1 = INTEGER: 36
.1.0.8802.1.1.2.1.4.2.1.5.0.36.1.1.4.192.168.85.1 = OID: .0.0