跳转到内容
Ask AI

LLDP Configuration

此内容尚不支持你的语言。

[Command] show lldp neighborsinterface-name show lldp table

[Purpose] Show LLDP neighbors

[Parameter]

ParameterDescription
interface-nameInterface name

[View] System view

[Use Cases]

sonic# show lldp neighbors
-------------------------------------------------------------------------------
LLDP neighbors:
-------------------------------------------------------------------------------
Interface: Ethernet1, via: LLDP, RID: 78, Time: 0 day, 08:17:51
Chassis:
ChassisID: local 60:eb:5a:01:1c:eb
SysName: Leaf-4-SZ
SysDescr: CX204Y-48GT-M-AC Debian GNU/Linux 9 (stretch) 5.10.34-103 aarch64
MgmtIP: 172.18.0.1
MgmtIface: 10
MgmtIP: fe80::9013:e0ff:fe83:e51e
MgmtIface: 6
Capability: Bridge, on
Capability: Router, on
Port:
PortID: ifname Ethernet16
PortDescr: Ethernet16
TTL: 8
MFS: 9216
PMD autoneg: supported: no, enabled: no
MAU oper type: 10BaseTFD - UTP MAU, full duplex mode
VLAN: 202, pvid: yes vlan202
VLAN: 4094, pvid: no vlan4094
-------------------------------------------------------------------------------

[Command] show lldp ports med-policy

[Purpose] Display interface LLDP MED configuration policy

[View] System view

[Use Cases]

sonic# show lldp ports med-policy
+------------+---------------+--------+----------+------------+--------+
| Ports | application | vlan | tagged | priority | dscp |
+============+===============+========+==========+============+========+
| Ethernet20 | voice | 20 | NA | NA | NA |
+------------+---------------+--------+----------+------------+--------+

[Command] lldp enable no lldp enable

[Purpose] Enable LLDP

[View] System configuration view

[Use Cases]

sonic(config)# lldp enable

[Command] lldp mgmt-ipA.B.C.D

[Purpose] Configure the management IP address of LLDP

[View] System configuration view

[Usage Scenario] Configuring a management address is useful for clearly identifying a device, aiding in network topology mapping, and facilitating network management. When there’s a need to advertise a specific management address to neighbors, this command is used for configuration.

[Notes] The management address is carried in the Management Address TLV field of LLDP packets, uniquely identifying a device. By default, it is set to the IP address of the management interface. If the management interface address is not configured, it will default to the Docker container’s internal address.

[Use Cases]

sonic(config)# lldp mgmt-ip 10.1.0.15

[Command] lldp port-id-subtype {macaddress|ifname}

[Purpose] Configure the interface ID type of LLDP

[Parameter]

ParameterDescription
macaddressMAC Address
ifnameInterface Name

[View] System configuration view

[Usage Scenario] In the LLDP table, the interface IP used in the mode is the device’s interface name. To clearly identify interconnected devices, you can configure the interface ID type as a MAC address.

By default, the interface ID type is set to “ifname.”.

[Use Cases]

sonic(config)# lldp port-id-subtype macaddress