Passion/Network

LLDP

sunshout 2014. 7. 10. 10:28

LLDP : Link Layer Discovery Protocol

- LLDP is discovery protocol between two direct interface.

- for example, host A and L2 Switch



Installation

$ apt-get install lldp


Test

- following result shows that gaus02 discovered a neighbor called "gaus01-m.ngvt.com"

- One of node's mac address become ChassisID

- If it has other ports, it listed in a Port

root@gaus02-m:~# lldpcli show neighbors

-------------------------------------------------------------------------------

LLDP neighbors:

-------------------------------------------------------------------------------

Interface:    eth1, via: LLDP, RID: 1, Time: 0 day, 00:00:14

  Chassis:

    ChassisID:    mac a0:36:9f:15:a8:3e

    SysName:      gaus01-m.ngvt.com

    SysDescr:     Ubuntu 14.04 LTS Linux 3.13.0-29-generic #53-Ubuntu SMP Wed Jun 4 21:00:20 UTC 2014 x86_64

    MgmtIP:       192.168.1.1

    Capability:   Bridge, on

    Capability:   Router, off

    Capability:   Wlan, off

  Port:

    PortID:       mac 90:e2:ba:35:ad:b0

    PortDescr:    p3p1

-------------------------------------------------------------------------------

root@gaus02-m:~#


LLDP is useful for identify interface name of neighbor.

Port is directly connected interface. So p3p1 is directly connected interface with gaus02-m and my port which is directly connected interface is eth1.


Juniper Serios (show lldp neighbors)

root@ex4550> show lldp neighbors

Local Interface    Parent Interface    Chassis Id          Port info          System Name

xe-0/0/24.0        -                   00:25:90:e5:62:52   p2p1               cnode25-m.testbed.net

xe-0/0/20.0        -                   00:25:90:e5:62:52   p2p2               cnode25-m.testbed.net

me0.0              -                   00:8e:f2:5a:d9:d2   2/g45

xe-0/0/15.0        -                   90:b1:1c:9f:9e:2d   p1p1               gateway-m

xe-0/0/8.0         -                   90:b1:1c:9f:9e:2d   p1p2               gateway-m

MIB


MIB-Tree lldpObjects (1.0.8802.1.1.2.1)


참고:

Juniper netconf : http://www.juniper.net/techpubs/en_US/junos14.1/information-products/topic-collections/junos-xml-ref-oper/index.html