lldp enable (Interface view)

Function

The lldp enable command run in the interface view enables Link Layer Discovery Protocol (LLDP) on an interface.

The undo lldp enable command run in the interface view disables LLDP on an interface.

If LLDP is enabled globally, LLDP by default takes effect on all main interfaces on the device,LLDP is not enabled on the sub-interface. You need to enable LLDP manually.If LLDP is disabled globally, LLDP does not take effect on any interface.

Format

lldp enable

undo lldp enable

Parameters

None

Views

Layer 2 100GE interface view, 100ge sub-interface view, 100GE interface view, Layer 2 10GE interface view, 10GE sub-interface view, 10GE interface view, 200GE sub-interface view, 25GE-L2 view, 25GE sub-interface view, 25GE interface view, 400GE-L2 view, 400GE sub-interface view, 400GE interface view, Layer 2 40GE interface view, 40GE sub-interface view, 40GE interface view, Layer 2 50GE interface view, 50GE sub-interface view, 50GE interface view, Eth-Trunk sub-interface view, FlexE-100G interface view, FlexE-400G interface view, FlexE-50G interface view, FlexE-50|100G interface view, FlexE interface view, Layer 2 GE interface view, GE optical interface view, GE sub-interface view, GE interface view, GE electrical interface view, Global VE sub-interface view, PW-VE sub-interface view, VE sub-interface view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
lldp write

Usage Guidelines

Usage Scenario

If LLDP is enabled on a device, the device can use specified interfaces to exchange LLDP packets with neighbors, learning neighbor status information while sending local status information to neighbors. By collecting status information stored on each network device, the NMS can discover the overall network topology.

Note that LLDP takes effect on a device only after LLDP is enabled globally and on specified interfaces. If LLDP is disabled on an interface, the device cannot use this interface to exchange LLDP packets with neighbors. The lldp enable command allows you to enable LLDP on a specific interface.

Prerequisites

LLDP has been enabled globally using the lldp enable command in the system view.

Precautions

LLDP can be enabled globally or on an interface. The relationships are as follows:

  • By default, LLDP is enabled on all interfaces after LLDP is enabled globally, LLDP is disabled on the sub-interface.
  • LLDP is disabled on all interfaces after LLDP is disabled globally.

    Note: Disabling LLDP globally does not affect the LLDP alarm function.
  • An interface can send and receive LLDP packets only after LLDP is enabled globally and on the interface.
  • The command to enable or disable LLDP on an interface is invalid after LLDP is disabled globally.

    If the device supports the POS interface, the lldp function of the interface will be invalid if the link protocol fr command is configured on a POS interface.

    If the sub-interfaces supported by the device contain Ethernet, Flex-eth types, the LLDP functionality can be configured on the sub-interfaces, and the other sub-interfaces do not support LLDP.

Example

# Enable LLDP on GigabitEthernet 0/1/1.1.
<HUAWEI> system-view
[~HUAWEI] lldp enable
[*HUAWEI] interface GigabitEthernet 0/1/1
[*HUAWEI-GigabitEthernet0/1/1] lldp enable
[*HUAWEI-GigabitEthernet0/1/1] lldp vlan-mode enable
[*HUAWEI-GigabitEthernet0/1/1.1] vlan-type dot1q 1
[*HUAWEI-GigabitEthernet0/1/1.1] lldp enable
# Enable LLDP on GigabitEthernet 0/1/1.
<HUAWEI> system-view
[~HUAWEI] lldp enable
[*HUAWEI] interface GigabitEthernet 0/1/1
[*HUAWEI-GigabitEthernet0/1/1] lldp enable
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >