No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Command Reference

S1720, S2700, S5700, and S6720 V200R011C10

This document describes all the configuration commands of the device, including the command function, syntax, parameters, views, default level, usage guidelines, examples, and related commands.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
LLDP Configuration Commands

LLDP Configuration Commands

Command Support

Commands provided in this section and all the parameters in the commands are supported by all switch models by default, unless otherwise specified. For details, see specific commands.

cdp clear neighbor

Function

The cdp clear neighbor command clears CDP neighbors in the system or on an interface of the device.

Format

cdp clear neighbor [ interface interface-type interface-number ]

Parameters

Parameter

Description

Value

interface interface-type interface-number

Indicates the type and number of the interface whose CDP neighbors are to be cleared. In the command:
  • interface-type specifies the type of the interface.
  • interface-number specifies the number of the interface.

If no interface is specified, this command clears CDP neighbors on all interfaces.

-

Views

User view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

If you want to obtain the latest CDP neighbor information of interfaces, use the cdp clear neighbor command to clear existing CDP neighbors. When an interface receives new CDP packets, new CDP neighbors are generated.

Prerequisites

The LLDP function has been enabled globally and on interfaces, and the lldp compliance cdp receive command has been run to enable CDP-compatible LLDP on interfaces.

Example

# Clear CDP neighbors on all the interfaces.

<HUAWEI> cdp clear neighbor
Warning: This command will clear CDP neighbor information of all the ports. Continue? [Y/N]:y

display cdp local

Function

The display cdp local command displays local CDP information on a specified interface or all interfaces.

Format

display cdp local [ interface interface-type interface-number ]

Parameters

Parameter Description Value
interface interface-type interface-number
Displays the CDP local information on a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If this parameter is not specified, the command displays CDP local information on all the interfaces.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

To check CDP information on a specified interface or all interfaces, run the display cdp local information.

Prerequisites

LLDP has been enabled globally using the lldp enable (system view) command, and LLDP compatibility with CDP has been enabled on the specified interface using the lldp compliance cdp receive command.

Example

# Display CDP local information on all the interfaces.

<HUAWEI> display cdp local
Remote Table Statistics:
-------------------------------------------------------------------------- 
Remote Table Last Change Time   :0 days, 23 hours, 21 minutes, 37 seconds
Remote Neighbors Added             :0
Remote Neighbors Deleted           :0
Remote Neighbors Dropped           :0
Remote Neighbors Aged              :0
Total Neighbors                    :1

Port information:
--------------------------------------------------------------------------   
Interface GigabitEthernet0/0/1:
CDP Status               :enabled             (default is disabled)             
Total Neighbors          :1  
Interface GigabitEthernet0/0/2:
CDP Status               :enabled      (default is disabled)            
Total Neighbors          :0
  ---- More ----  
Table 16-30  Description of the display cdp local command output.

Item

Description

Remote Table Statistics

Statistics about CDP neighbors.

Remote Table Last Change Time

Time of the latest update of the CDP neighbor table.

Remote Neighbors Added

Number of added CDP neighbors.

Remote Neighbors Deleted

Number of deleted CDP neighbors.

Remote Neighbors Dropped

Number of CDP neighbors that are deleted because of insufficient storage memory.

Remote Neighbors Aged

Number of CDP neighbors that are deleted by the aging mechanism.

Total Neighbors

Total number of CDP neighbors.

Port information

Local CDP information on all interfaces of the switch.

Interface x

Local CDP information on the x interface.

CDP Status

Whether LLDP compatibility with CDP is enabled on the interface:
  • enabled
  • disabled

You can run the lldp compliance cdp receive command to configure this parameter.

Total Neighbors

Total number of CDP neighbors on the interface.

display cdp neighbor

Function

The display cdp neighbor command displays information about CDP neighbors of all interfaces or a specified interface.

Format

display cdp neighbor [ interface interface-type interface-number ]

Parameters

Parameter Description Value
interface interface-type interface-number
Displays information about CDP neighbors of a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.
If this parameter is not specified, the command displays information about CDP neighbors of all interfaces.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

This command enables you to know which CDP neighbors the local device has, Layer 2 information about the neighbors, and to which interfaces the neighbors connect. You can also use this command to check whether the Layer 2 information is configured correctly on the neighbors.

Prerequisites

LLDP has been enabled globally using the lldp enable (system view) command, and LLDP compatibility with CDP has been enabled on the specified interface using the lldp compliance cdp receive command.

Example

# Display information about CDP neighbors of all the interfaces.

<HUAWEI> display cdp neighbor
GigabitEthernet0/0/1 has 1 neighbor(s):
                       
Neighbor index :1       
Device ID                :ME3400  
Port ID                  :GigabitEthernet0/4 
Version                  :SCCP75.8-3-3SR2S
Platform                 :cisco ME-3400EG-2CS-A
Capabilities             :Host phone
MacAddress               :b4a4-e3cf-e984
Discovered time          :0 days, 22 hours, 33 minutes, 36 seconds     
Expired time             :122                                
Power drawn              :12000 mw 
Power request ID         :39308 
Power management ID      :2 
Power request levels     :12000 mw 0 mw
  ---- More ----  
Table 16-31  Description of the display cdp neighbor command output

Item

Description

m has n neighbor(s) The interface m has n CDP neighbors.

Neighbor index

Index of a CDP neighbor.

Device ID

ID of the CDP neighbor.

Port ID

Interface of the CDP neighbor connecting to the switch.

Version

Version of the CDP neighbor.

Platform

Software platform of the CDP neighbor.

Capabilities
Type fo the CDP neighbor:
  • Host Phone: host and IP phone
  • Phone: IP phone
  • Host

If the CDP neighbor is neither a host nor an IP phone, the Capabilities field is not displayed.

MacAddress

MAC address of the CDP neighbor.

Discovered time

Time when the CDP neighbor was discovered, that is, the time difference between the system time when the device discovers the CDP neighbor and the startup time of the switch.

Expired time

The aging time remaining of CDP neighbor, in seconds.

Power drawn

Power set on the source.

Power request ID

Requested power ID.

Power management ID

ID used to manage power. The ID is the number of times the power is changed.

Power request levels

Requested power level. The maximum power among the negotiated power values is selected.

display cdp neighbor brief

Function

The display cdp neighbor brief command displays brief information about CDP neighbors of the device.

Format

display cdp neighbor brief

Parameters

None

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

You can run this command to quickly view brief information about CDP neighbors connected to a switch, such as CDP neighbor names and interfaces on which CDP neighbor relationships are set up.

Prerequisites

LLDP has been enabled globally using the lldp enable (system view) command, and LLDP compatibility with CDP has been enabled on the specified interface using the lldp compliance cdp receive command.

Example

# Display brief information about CDP neighbors.

<HUAWEI> display cdp neighbor brief
Local Intf   Neighbor Dev             Neighbor Intf             Exptime(s)
GE0/0/1      ME3400                   GE0/0/4                   144
Table 16-32  Description of the display cdp neighbor brief command output

Item

Description

Local Intf

Local interface of the switch that sets up a CDP neighbor relationship with a peer device.

Neighbor Dev

Name of a CDP neighbor.

Neighbor Intf

Interface of a peer device that sets up a CDP neighbor relationship with the switch.

Exptime(s)

Time left before a CDP neighbor relationship expires, in seconds.

display cdp statistics

Function

The display cdp statistics command displays statistics about CDP packets received.

Format

display cdp statistics [ interface interface-type interface-number ]

Parameters

Parameter Description Value
interface interface-type interface-number
Displays statistics about CDP packets received by a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If this parameter is not specified, the command displays statistics about CDP packets received by all the interfaces.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

When you need to locate an LLDP fault on a switch according to statistics about CDP packets received, run the display cdp statistics command.

NOTE:

To check statistics about CDP packets received in a specified period of time, run the reset cdp statistics command to clear the historical CDP packet statistics. Wait for the specified period of time, and then run the display cdp statistics command to check the new CDP packet statistics.

Prerequisites

LLDP has been enabled globally using the lldp enable (system view) command, and LLDP compatibility with CDP has been enabled on the specified interface using the lldp compliance cdp receive command.

Example

# Display statistics about CDP packets received by all interfaces.

<HUAWEI> display cdp statistics
CDP statistics global Information:
Statistics for GigabitEthernet0/0/1:
Total frames received:    30                                                    
Total frames discarded:   0                                                     
Total frames error:       0                                                     
Last cleared time:        never 
  ---- More ----
Table 16-33  Description of the display cdp statistics command output

Item

Description

CDP statistics global Information

Statistics about CDP packets received by the switch.

Statistics for x

Statistics about CDP packets received by the x interface.

Total frames received

Number of received CDP packets by this interface.

Total frames discarded

Number of discarded CDP packets by this interface.

Total frames error

Number of received CDP error packets by this interface.

Last cleared Time

Time when the statistics about CDP packets received on this interface are cleared last time:
  • If the statistics about CDP packets on this interface have been cleared, the time is displayed.
  • If the statistics about CDP packets on this interface have never been cleared, never is displayed.

display lldp local

Function

The display lldp local command displays global LLDP information or the LLDP information on a specified interface.

Format

display lldp local [ interface interface-type interface-number ]

Parameters

Parameter Description Value
interface interface-type interface-number
Displays the LLDP information on a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If no interface is specified, the command displays LLDP information on all the interfaces with LLDP enabled.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

The display lldp local command displays the global LLDP information or the LLDP information on an interface.
  • The global LLDP information includes system information, MED system information, system configuration, and data statistics on the peer device.
  • The LLDP information on an interface includes the interface information and MED interface information.

To verify the LLDP information and Layer 2 information of the system and interfaces, run this command.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Example

# Display the global LLDP information, S5720-56C-HI-AC is used as an example.

<HUAWEI> display lldp local
System information                                                              
--------------------------------------------------------------------------
Chassis type   :MAC address                                                      
Chassis ID     :00e0-11fc-1710                                                  
System name    :HUAWEI       
System description  :S5720-56C-HI-AC 
Huawei Versatile Routing Platform Software  
VRP (R) software,Version 5.170 (S5720 V200R011C10 ) 
Copyright (C) 2000-2015 HUAWEI TECH Co., Ltd.
System capabilities supported   :bridge router                                          
System capabilities enabled     :bridge router                                         
LLDP Up time   :2015-01-22 13:29:26                                              
                                                                                
MED system information                                                         
--------------------------------------------------------------------------
Device class   :Network Connectivity                                            
(MED inventory information of master board)                                     
HardwareRev       :VER.B                                              
FirmwareRev       :NA                                                         
SoftwareRev       :Version 5.1670 V200R011C10                                  
SerialNum         :NA                                                           
Manufacturer name :HUAWEI TECH Co., Ltd.                                                           
Model name        :NA                                                           
Asset tracking identifier :NA
                                                   
System configuration
--------------------------------------------------------------------------
LLDP Status                     :enabled             (default is enabled)
LLDP Message Tx Interval        :30                  (default is 30s)
LLDP Message Tx Hold Multiplier :4                   (default is 4)
LLDP Refresh Delay              :2                   (default is 2s)
LLDP Tx Delay                   :2                   (default is 2s)
LLDP Notification Interval      :5                   (default is 5s)
LLDP Notification Enable        :enabled             (default is enabled)
Management Address              :IP:10.10.10.1      MAC:000b-09e6-3da1

Remote Table Statistics:
--------------------------------------------------------------------------
Remote Table Last Change Time   :0 days, 0 hours, 4 minutes, 15 seconds                                                             
Remote Neighbors Added          :5                                                                                                  
Remote Neighbors Deleted        :0                                                                                                  
Remote Neighbors Dropped        :0                                                                                                  
Remote Neighbors Aged           :0                                                                                                  
Total Neighbors                 :5                                                                                                  
                                                                                                                                    
Port information:      
--------------------------------------------------------------------------                                                 
Interface GigabitEthernet0/0/1:                              
LLDP Enable Status       :enabled             (default is enabled)             
Total Neighbors          :1                                                     
                                                                                
Port ID subtype     :Interface name                                              
Port ID             :GigabitEthernet0/0/1             
Port description    :GigabitEthernet0/0/1
                                                                                
Port and protocol VLAN ID(PPVID)   :0  
Port and protocol VLAN supported   :No
Port and protocol VLAN enabled     :No 
Port VLAN ID(PVID)  :1                                                          
VLAN name of VLAN 1: VLAN0001                                                      
Protocol identity   :STP RSTP/MSTP LACP EthOAM CFM                              
                                                                                
Auto-negotiation supported    :Yes                                              
Auto-negotiation enabled      :Yes                                              
OperMau   :speed(1000)/duplex(Full)     
                                                                                
Power port class         :PD                                                    
PSE power supported      :No                                                    
PSE power enabled        :No                                                    
PSE pairs control ability:No                                                    
Power pairs              :Unknown                                               
Port power classification:Unknown                                               
                                                                                
Link aggregation supported:Yes                                                  
Link aggregation enabled :No                                                    
Aggregation port ID      :0                                                     
Maximum frame Size       :1526                                                  

EEE support              :Yes
Transmit Tw              :36
Receive Tw               :36
Fallback Receive Tw      :36
Echo Transmit Tw         :36
Echo Receive Tw          :36
                                                                                
MED port information                                                            
                                                                                
Media policy type   :Unknown                                                    
Unknown Policy      :Yes                                                        
VLAN tagged         :No                                                         
Media policy VlanID           :0                                                
Media policy L2 priority      :0                                                
Media policy Dscp             :0                                                
                                                                                
Power Type               :Unknown                                               
PoE PSE power source     :Unknown                                               
Port PSE Priority        :Unknown                                               
Port Available power value:0.2(w)                                               
                                                                                
  ---- More ----                                                                
Table 16-34  Description of the display lldp local command output.

Item

Description

System information

Global LLDP information.

Chassis type

Type of the Device ID:
  • Chassis component: chassis alias
  • Interface alias: interface alias
  • Port component: interface or backplane alias
  • MAC address: MAC address
  • Network address: network address
  • Interface name: name of the interface
  • Locally assigned: name of the local device

Chassis ID

Device ID.

System name

Name of the device.

System description

Description of the device.

Huawei Versatile Routing Platform Software

-

VRP (R) software, Version

Versions of the VRP and the software of the device.

Copyright (C) 2000-2013 HUAWEI TECH Co., Ltd.

Huawei copyright.

System capabilities supported

Capabilities supported of the local device, including:
  • bridge: bridge device
  • router: router

System capabilities enabled

Capabilities enabled on the local device.

LLDP Up time

Time when LLDP is enabled.

MED system information

MED TLV information of the device.

Device class

Type of the device.

MED inventory information of master board -

HardwareRev

Hardware version of the device.

FirmwareRev

Firmware version of the device.

SoftwareRev

Software version of the device.

SerialNum

Serial number of the device.

NOTE:

If the decimal value of a serial number is not in the range of 32 to 126, the serial number is displayed in octal notation.

Manufacturer name

Name of the manufacturer

Model name

Name of a model.

Asset tracking identifier

Asset tracking ID.

System configuration

Global LLDP configuration.

LLDP Status

Whether LLDP is enabled globally on the switch:
  • Enabled
  • Disabled

You can run the lldp enable (system view) command to configure this parameter.

default is x

Default value x.

LLDP Message Tx Interval

Interval for sending LLDP packets of the device, in seconds.

You can run the lldp message-transmission interval command to configure this parameter.

LLDP Message Tx Hold Multiplier

Hold time multiplier of local device information stored on neighbors.

You can run the lldp message-transmission hold-multiplier command to configure this parameter.

LLDP Refresh Delay

Delay in re-enabling the LLDP function on the switch, in seconds.

You can run the lldp restart-delay command to configure this parameter.

LLDP Tx Delay

Delay in sending LLDP packets on the switch, in seconds.

You can run the lldp message-transmission delay command to configure this parameter.

LLDP Notification Interval

Delay in sending the neighbor change traps to the NMS on the switch, in seconds.

You can run the lldp trap-interval command to configure this parameter.

LLDP Notification Enable

Whether the function of sending LLDP traps to the NMS is enabled on the switch:
  • enabled
  • disabled

You can run the snmp-agent trap enable feature-name lldptrap command to configure this parameter.

Management Address

LLDP management address of the switch.

You can run the lldp management-address command to configure this parameter.

If an invalid management address is used, the inactive field is added for this address. For example, if 10.1.1.1 is an invalid management address, the displayed information is as follows: Management Address :IP:10.10.10.1, 10.1.1.1 (inactive) MAC:000b-09e6-3da1

Remote Table Statistics

Statistics about LLDP neighbors.

Remote Table Last Change Time

Time that elapsed since the latest modification of remote data.

Remote Neighbors Added

Number of added LLDP neighbors.

Remote Neighbors Deleted

Number of deleted LLDP neighbors.

Remote Neighbors Dropped

Number of devices that do not set up LLDP neighbor relationships because the number of neighbors has reached the maximum value.

Remote Neighbors Aged

Number of LLDP neighbors that are aged out and deleted.

Total Neighbors

Number of LLDP neighbors.

Port information

LLDP information on the interface.

LLDP Enable Status

Whether LLDP is enabled on the interface:
  • Enabled
  • Disabled

You can run the lldp enable (system view) and lldp enable (interface view) commands to configure this parameter.

Total Neighbors

Number of LLDP neighbors on the interface.

Port ID subtype

Type of the interface ID.
  • Interface alias: interface alias
  • Port component: interface or backplane alias
  • MAC address: MAC address
  • Network address: network address
  • Interface name: name of the interface
  • Agent circuit ID: circuit ID of the DHCP agent
  • Locally assigned: name of the local device

Port ID

Interface ID.

Port description

Interface description.

Port and protocol VLAN ID(PPVID) Protocol VLAN ID of a port.
Port and protocol VLAN supported Whether PPVID is supported:
  • Yes: PPVID is supported.
  • No: PPVID is not supported.
Port and protocol VLAN enabled Whether PPVID is enabled:
  • Yes: PPVID is enabled.
  • No: PPVID is disabled.

Port VLAN ID(PVID)

The default VLAN ID of the interface.

VLAN name of VLAN 1

Name of VLAN 1.

Protocol identity

Protocol ID.

Auto-negotiation supported

Whether the interface supports auto-negotiation:
  • Yes
  • No

For details about Ethernet interfaces supporting the auto-negotiation function, see Licensing Requirements and Limitations for Ethernet Interfaces.

Auto-negotiation enabled

Whether the interface is enabled with auto-negotiation:
  • Yes
  • No

You can run the negotiation auto command to configure this parameter.

OperMau

Rate and duplex mode of the interface.

Power port class

PoE type of the interface:
  • PSE: power-sourcing equipment
  • PD: powered device

PSE power supported

Whether the PSE power is supported.
  • Yes: PSE power is supported.
  • No: PSE power is not supported.

PSE power enabled

Whether the PSE power is enabled.
  • Yes: enabled.
  • No: disabled.

PSE pairs control ability

Whether the PSE twisted pair control is supported.
  • Yes: PSE twisted pair control is supported.
  • No: PSE twisted pair control is not supported.

Power pairs

PoE remote power supply mode.
  • Signal: power supply mode of signal lines
  • Spare: power supply mode of spare signal lines
  • Unknown: an unknown remote power supply mode

Port power classification

PD power control level on the interface:
  • Class0: indicates level 1.
  • Class1: indicates level 2.
  • Class2: indicates level 3.
  • Class3: indicates level 4.
  • Class4: indicates level 5.
  • Unknown: indicates an unknown level.

Link aggregation supported

Whether the interface supports link aggregation.

  • Yes: The interface supports link aggregation.
  • No: The interface does not support link aggregation.

Link aggregation enabled

Whether link aggregation is enabled on the interface.

  • Yes: enabled
  • No: disabled

Aggregation port ID

ID of an aggregated interface, If link aggregation is disabled, the value of this field is 0.

Maximum frame Size

Maximum size of a frame supported by the interface.

You can run the jumboframe enable command to configure this parameter.

EEE support

Whether the interface supports energy efficient Ethernet (EEE):
  • Yes
  • No

Transmit Tw

Amount of time the sender waits before starting sending data after leaving lower power consumption mode(LPI mode).

Receive Tw

Amount of time the receiver expects the sender to wait before starting sending data after leaving LPI mode.

Fallback Receive Tw

Additional information provided to the sender.

Echo Transmit Tw

Transmit Tw value specified in the Echo message sent from the remote end.

Echo Receive Tw

Receive Tw value specified in the Echo message sent from the remote end.

MED port information

-

Media policy type

Type of the media policy:
  • Voice.
  • Voice Signaling.
  • Guest Voice.
  • Guest Voice Signaling.
  • Softphone Voice.
  • Video Conferencing.
  • Streaming Video.
  • Video Signaling.
  • Unknown

Unknown Policy

Whether the type of the media policy is unknown:
  • Yes: unknown
  • Defined: known
  • Unknown: indicates that the Media policy VlanID, Media policy L2 priority and Media policy Dscp value fields are ignored.

VLAN tagged

Whether to add tag to the packets of the voice VLAN.
  • Yes: Adds a VLAN tag to packets of the voice VLAN.
  • No: Not to add a VLAN tag to packets of the voice VLAN.

Media policy VlanID

ID of the voice VLAN.

Media policy L2 priority

802.1p priority.

Media policy Dscp

DSCP value.

Power Type

Power supply type.

Layer 3 interfaces do not support PoE TLV, so this parameter is not displayed on Layer 3 interfaces.

PoE PSE power source

Type of the PSE:
  • Primary: indicates primary power supply.
  • Backup: indicates backup power supply.
  • Unknown: indicates power supply of an unknown type.

Layer 3 interfaces do not support PoE TLV, so this parameter is not displayed on Layer 3 interfaces.

Port PSE Priority

PSE priority of an interface:
  • Unknown: indicates an unknown priority.
  • Critical: indicates the highest priority.
  • High: indicates the medium priority.
  • Low: indicates the lowest priority.

Layer 3 interfaces do not support PoE TLV, so this parameter is not displayed on Layer 3 interfaces.

Port Available power value

Port power supply.

Layer 3 interfaces do not support PoE TLV, so this parameter is not displayed on Layer 3 interfaces.

display lldp neighbor

Function

The display lldp neighbor command displays information about neighboring device of all interfaces or a specified interface.

Format

display lldp neighbor [ interface interface-type interface-number ]

Parameters

Parameter

Description

Value

interface interface-type interface-number

Displays information about neighboring devices of a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If no interface is specified, the command displays information about neighboring devices of all interfaces with LLDP enabled.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

Using this command, you can know which neighboring devices are connected to the local device, to which interfaces the neighboring devices are connected, layer 2 information about the neighbors, and whether LLDP configuration is correct.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Example

# Display information about neighbor devices of interfaces GigabitEthernet0/0/1.

<HUAWEI> display lldp neighbor interface gigabitethernet0/0/1
GigabitEthernet0/0/1 has 1 neighbor(s):                                     
                                                                                
Neighbor index : 1                                                              
Chassis type   :MAC address  
Chassis ID     :00e0-11fc-1710                                                  
Port ID type   :Interface name                                                   
Port ID        :GigabitEthernet0/0/1                                    
Port description    :GigabitEthernet0/0/1     
System name         :HUAWEI                                                    
System description  :S5720-56C-HI-AC
Huawei Versatile Routing Platform Software 
VRP (R) software,Version 5.160 (S5720 V200R011C10) 
Copyright (C) 2000-2015 HUAWEI TECH CO., LTD
System capabilities supported   :bridge router                                         
System capabilities enabled     :bridge router                                         
Management address type  :ipv4                                                  
Management address value : 127.0.0.1                                            
OID  :0.6.15.43.6.1.4.1.2011.5.25.41.1.2.1.1.1.
Expired time   :104s                                                            
                                                                                
                                                                                
Port VLAN ID(PVID)  :1                                                          
Port and protocol VLAN ID(PPVID)   :0  
Port and protocol VLAN supported   :No
Port and protocol VLAN enabled     :No
VLAN name of VLAN  1: VLAN 0001                                                     
Protocol identity   :                              
                                                                                
Auto-negotiation supported    :Yes                                              
Auto-negotiation enabled      :Yes                                              
OperMau   :speed(1000)/duplex(Full)                                             
                                                                                
Power port class         :PD                                                    
PSE power supported      :No                                                    
PSE power enabled        :No                                                    
PSE pairs control ability:No                                                    
Power pairs              :Unknown                                               
Port power classification:Unknown                                               
Power type                  :Type 2 PD
Power source                :PSE
Power priority              :Low
PD requested power value    :60.0(w)
PSE allocated power value   :60.0(w)
PD requested power mode A value  :30.0(w)
PD requested power mode B value  :30.0(w)
Power class                      :6
Power typex                      :Type 3 PSE
PSE allocated power mode A value :0.0(w)
PSE allocated power mode B value :0.0(w)
PSE maximum available power      :0.0(w)
PSE power pairsx                 :Unknown
PSE Autoclass support            :PSE does not supports Autoclass
PD 4PID                          :PD does not supports powering of both Modes
PD Load                          :PD is single-signature or dual-signature and power demand on Mode A and Mode B are not electrically isolated
Autoclass completed              :Autoclass idle
Autoclass request                :Autoclass idle
Power down                       :Not power down
                                                                                
Link aggregation supported:Yes                                                  
Link aggregation enabled :No                                                    
Aggregation port ID      :0                                                     
Maximum frame Size       :9216                                               

EEE support              :Yes
Transmit Tw              :36
Receive Tw               :36
Fallback Receive Tw      :36
Echo Transmit Tw         :36
Echo Receive Tw          :36
                                                                                
MED Device information                                                          
Device class   :Network Connectivity                                            
                                                                                
HardwareRev       :VER.A                                               
FirmwareRev       :NA                                                           
SoftwareRev       :Version 5.160 V200R011C10                                 
SerialNum         :NA                                                           
Manufacturer name :HUAWEI TECH CO., LTD                                                           
Model name        :NA                                                           
Asset tracking identifier :NA                                                   
                                                                                
Media policy type   :Voice                                                    
Unknown Policy      :Defined                                                         
VLAN tagged         :Yes                                                         
Media policy VlanID      :0                                                     
Media policy L2 priority :6                                                     
Media policy Dscp        :46                                                     
                                                                                
Power Type               :Unknown                                               
PoE PSE power source     :Unknown                                               
Port PSE Priority        :Unknown                                               
Port Available power value:0.2(w)                                                    
Table 16-35  Description of the display lldp neighbor command output

Item

Description

Neighbor index

Index of a neighbor.

Chassis type

ID sub-types of a neighboring device:
  • Chassis component: chassis alias
  • Interface alias: interface alias
  • Port component: interface or backplane alias
  • MAC address: MAC address
  • Network address: network address
  • Interface name: name of the interface
  • Locally assigned: name of the local device

Chassis Id

ID of a neighboring device.

Port ID type

ID sub-type of a neighboring interface:
  • Interface alias: interface alias
  • Port component: interface or backplane alias
  • MAC address: MAC address
  • Network address: network address
  • Interface name: name of the interface
  • Agent circuit ID: circuit ID of the DHCP agent
  • Locally assigned: name of the local device

Port Id

ID of a neighbor interface.

Port description

Description of a neighboring interface.

System name

System name of a neighboring device.

System description

Description of a neighboring device.

System capabilities supported

Capabilities of a neighboring device (at least one capability is supported):
  • other: other capabilities
  • repeater: repeater
  • bridge: bridge device
  • wlanAccessPoint: wireless access point
  • router: router
  • telephone: wireless device
  • docsisCableDevice: management station
  • stationOnly: base station

System capabilities enabled

Capabilities enabled on a neighboring device (This field is a subset of the system capabilities supported field, and at least one capability must be enabled).
  • other: other capabilities
  • repeater: repeater
  • bridge: bridge device
  • wlanAccessPoint: wireless access point (AP)
  • router: router
  • telephone: wireless device
  • docsisCableDevice: management station
  • stationOnly: base station

Management address value

Management address of a neighbor.

Management address

Management address of a neighbor.

OID

Neighbor management address OID.

Expired time

Aging time of a neighbor.

Port VLAN ID(PVID)

VLAN ID of an interface.

Port and protocol VLAN ID(PPVID) Protocol VLAN ID of a port.
Port and protocol VLAN supported Whether PPVID is supported:
  • Yes: PPVID is supported.
  • No: PPVID is not supported.
Port and protocol VLAN enabled Whether PPVID is enabled:
  • Yes: PPVID is enabled.
  • No: PPVID is disabled.

VLAN name of VLAN 1

Name of VLAN 1.

Protocol identity

Protocol ID.

Auto-negotiation supported

Whether the interface supports auto-negotiation:
  • Yes: Auto-negotiation is supported.
  • No: Auto-negotiation is not supported.

Auto-negotiation enabled

Whether the interface is enabled with auto-negotiation:
  • Yes: enabled.
  • No: disabled.

OperMau

Transmission rate and duplex mode of the interface.

Power port class

PoE type:
  • PSE: power-sourcing equipment.
  • PD: powered device.

PSE power supported

Whether the PSE power is supported.
  • Yes: PSE power is supported.
  • No: PSE power is not supported.

PSE power enabled

Whether the PSE power is enabled.
  • Yes: enabled.
  • No: disabled.

PSE pairs control ability

Whether the PSE control is supported.
  • Yes: PSE control is supported.
  • No: PSE control is not supported.

Power pairs

PoE remote power supply mode.
  • Signal: power supply mode of signal lines.
  • Spare: power supply mode of spare signal lines.
  • Unknown: an unknown remote power supply mode.

Port power classification

PD power control level on the interface:
  • Class0: indicates level 1.
  • Class1: indicates level 2.
  • Class2: indicates level 3.
  • Class3: indicates level 4.
  • Class4: indicates level 5.
  • Unknown: indicates an unknown control level.
Power type The power supply type:
  • Type 1 PD: indicates the PD that does not support IEEE 802.3at.
  • Type 1 PSE: indicates the PSE that does not support IEEE 802.3at.
  • Type 2 PD: indicates the PD that supports IEEE 802.3at.
  • Type 2 PSE: indicates the PSE that supports IEEE 802.3at.
Power source The power supply source.
Power priority The power supply priority of an interface:
  • low
  • high
  • Critical
  • unknown
PD requested power value -
PSE allocated power value -
PD requested power mode A value -
PD requested power mode B value -
Power class
  • When the power type is PD this field shall be set to the requested Class of the PD.
  • When the power type is PSE this field shall be set to the PSEs assigned Class.
Power typex
  • Type 1 PSE
  • Type 1 PD
  • Type 2 PSE
  • Type 2 PD
  • Type 3 PSE
  • Type 3 single-signature PD
  • Type 4 PSE
  • Type 4 single-signature PD
  • Type 3 dual-signature PD
  • Type 4 dual-signature PD
PSE allocated power mode A value -
PSE allocated power mode B value -
PSE maximum available power The highest power the PSE can grant to the PD.
PSE power pairsx The power supply modes that the PSE supports:
  • Alternative A
  • Alternative B
  • Alternative A and Alternative B
  • Unknown
PSE Autoclass support Whether PSE supports Autoclass:
  • PSE supports Autoclass
  • PSE does not support Autoclass
PD 4PID
  • PD supports powering of both Modes
  • PD does not support powering of both Modes
PD Load
  • PD is dual-signature and power demand on Mode A and Mode B are electrically isolated
  • PD is single-signature or dual-signature and power demand on Mode A and Mode B are not electrically isolated
Autoclass completed Whether Autoclass is completed:
  • Autoclass measurement completed
  • Autoclass idle
Autoclass request Whether the interface has received Autoclass request:
  • PD requests Autoclass measurement
  • Autoclass idle
Power down Whether the interface powers down.

Link aggregation supported

Whether link aggregation is supported on the interface.

  • Yes: The interface supports link aggregation.
  • No: The interface does not support link aggregation.

Link aggregation enabled

Whether link aggregation is enabled on an interface.

  • Yes: The interface supports link aggregation.
  • No: The interface does not support link aggregation.

Aggregation port ID

ID of an aggregated interface, If link aggregation is disabled, the value of this field is 0.

Maximum frame Size

Maximum size of a frame supported by the interface.

EEE support

Whether the interface supports energy efficient Ethernet (EEE).

Transmit Tw

Amount of time the sender waits before starting sending data after leaving lower power consumption mode(LPI mode).

Receive Tw

Amount of time the receiver expects the sender to wait before starting sending data after leaving LPI mode.

Fallback Receive Tw

Additional information provided to the sender.

Echo Transmit Tw

Transmit Tw value specified in the Echo message sent from the remote end.

Echo Receive Tw

Receive Tw value specified in the Echo message sent from the remote end.

Device class

Type of the MED device.

HardwareRev

Hardware version of the device.

FirmwareRev

Firmware version of the device.

SoftwareRev

Software version of the device.

SerialNum

Serial number of the device.

NOTE:

If the decimal value of a serial number is not in the range of 32 to 126, the serial number is displayed in octal notation.

Manufacturer name

Name of the manufacturer.

Model name

Name of a model.

Asset tracking identifier

Asset tracking ID.

Media policy type

Type of the media policy:
  • Voice.
  • Voice Signaling.
  • Guest Voice.
  • Guest Voice Signaling.
  • Softphone Voice.
  • Video Conferencing.
  • Streaming Video.
  • Video Signaling.
  • unknown indicates that the type of the media policy is unknown.

Unknown Policy

Whether the type of the media policy is unknown:
  • Yes: unknown
  • Defined: known
  • Unknown: indicates that the Media policy VlanID, Media policy L2 priority and Media policy Dscp value fields are ignored.

VLAN tagged

Whether to add tag to the packets of the voice VLAN.

Media policy VlanID

ID of the voice VLAN.

Media policy L2 priority

Layer 2 priority.

Media policy Dscp

DSCP value.

Power Type

Power supply type:
  • PSE: power-sourcing equipment.
  • PD: powered device.
  • Unknown: an unknown power supply type.

PoE PSE power source

Type of the PSE:
  • Primary: indicates primary power supply.
  • Backup: indicates backup power supply.
  • Unknown: indicates power supply of an unknown type.

Port PSE Priority

PSE priority of an interface:
  • Unknown: indicates an unknown priority.
  • Critical: indicates the highest priority.
  • High: indicates the medium priority.
  • Low: indicates the lowest priority.

Port Available power value

Port power supply

display lldp neighbor brief

Function

The display lldp neighbor brief command displays brief information about neighbors of the device.

Format

display lldp neighbor brief

Parameters

None

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

To quickly view brief information about the LLDP neighbors of a switch and the interfaces connected to neighbors, run this command.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Example

# Display brief information about LLDP neighbors of the switch.

<HUAWEI> display lldp neighbor brief
Local Intf   Neighbor Dev             Neighbor Intf             Exptime(s)
GE0/0/1      Huawei                   GE0/0/1                   103
Table 16-36  Description of the display lldp neighbor brief command output

Item

Description

Local Intf

Local interface on which the LLDP neighbor relationship is established with a peer device.

Neighbor Dev

Name of an LLDP neighbor.

Neighbor Intf

Interface of a peer device on which the LLDP neighbor relationship is established.

Exptime

Time left before an LLDP neighbor relationship expires, in seconds.

display lldp statistics

Function

The display lldp statistics command displays statistics about LLDP packets sent and received by all or a specified interface.

Format

display lldp statistics [ interface interface-type interface-number ]

Parameters

Parameter

Description

Value

interface interface-type interface-number

Displays statistics about LLDP packet sent and received by a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If no interface is specified, the command displays statistics about LLDP packets on all interfaces.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

To display the LLDP packet statistics within a specified period of time, run the reset lldp statistics command to clear the existing statistics first, and then run the display lldp statistics command to display the new statistics.

Prerequisites

The LLDP function has been enabled globally and on the interface using the lldp enable (system view) and lldp enable (interface view) commands.

Precautions

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Example

# Display the statistics about LLDP packets sent and received by all interfaces.

<HUAWEI> display lldp statistics
LLDP statistics global Information:                                             
Statistics for GigabitEthernet0/0/1:                                            
Transmitted Frames Total: 2839                                                  
Received Frames Total:    2728      Frames Discarded Total:  0                  
Frames Error Total:       0         TLVs Discarded Total:    0                  
TLVs Unrecognized Total:  0         Neighbors Expired Total: 0                  
Table 16-37  Description of the display lldp statistics command output

Item

Description

LLDP statistics global Information

Statistics about LLDP packets.

Statistics for x

Statistics about LLDP packets received and sent by the x interface.

Transmitted Frames Total

Number of sent LLDP packets.

Received Frames Total

Number of received LLDP packets.

Frames Discarded Total

Number of discarded LLDP packets.

Frames Error Total

Number of received errored LLDP packets.

TLVs Discarded Total

Number of discarded TLVs.

TLVs Unrecognized Total

Number of unknown TLVs.

Neighbors Expired Total

Number of aged-out neighbors.

display lldp tlv-config

Function

The display lldp tlv-config command displays optional TLVs that can be sent with LLDP packets on all or a specified interface.

Format

display lldp tlv-config [ interface interface-type interface-number ]

Parameters

Parameter

Description

Value

interface interface-type interface-number

Displays optional TLVs supported by a specified interface.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If no interface is specified, the command displays optional TLVs on all interfaces.

-

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Usage Scenario

The display lldp tlv-config command displays the TLVs supported by the specified interface or all interfaces, and thus you can know whether the required TLVs are enabled and unneeded TLVs are disabled.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Example

# Display Optional TLVs that can be sent with LLDP packets on GigabitEthernet0/0/1.

<HUAWEI> display lldp tlv-config interface gigabitethernet 0/0/1

LLDP tlv-config of port [GigabitEthernet0/0/1]:
----------------------------------------------------                            
Name                               Status    Default                            
----------------------------------------------------                            
                                                                                
Basic optional TLV:                                                             
----------------------------------                                              
Port Description TLV               Yes       Yes                                
System Name TLV                    Yes       Yes                                
System Description TLV             Yes       Yes                                
System Capabilities TLV            Yes       Yes                                
Management Address TLV             Yes       Yes                                
                                                                                
IEEE 802.1 extend TLV:                                                          
----------------------------------                                              
Port VLAN ID TLV                   Yes       Yes                                
Port And Protocol VLAN ID TLV      Yes       Yes                                
VLAN Name TLV                      Yes       Yes                                
Protocol Identity TLV              No        No                                
                                                                                
IEEE 802.3 extend TLV:                                                          
----------------------------------                                              
MAC-Physic TLV                     Yes       Yes                                
Power Via MDI TLV                  Yes       Yes                                
Link Aggregation TLV               Yes       Yes                                
Maximum Frame Size TLV             Yes       Yes                                
EEE TLV                            Yes       Yes                                
                                                                                
LLDP-MED extend TLV:                                                            
----------------------------------                                              
Capabilities TLV                   Yes       Yes                                
Extended Power Via MDI TLV         Yes       Yes                                
Inventory TLV                      Yes       Yes                                
Network Policy TLV                 Yes       Yes                                
Location Identification TLV        No        No   
Table 16-38  Description of the display lldp tlv-config command output
Item Description
Name Type of TLV.
Status Whether the interface is configured to send the TLVs of the specified type.
Default Whether the TLVs of the specified types are sent on an interface by default.
Basic optional TLV Basic TLVs that can be sent on an interface.
Port Description TLV Interface description TLV.
System Name TLV System name TLV.
System Description TLV System description TLV.
System Capabilities TLV TLV indicating the system capability set.
Management Address TLV Management address TLV.
IEEE 802.1 extend TLV Type of the IEEE 802.1 organizational-specific TLVs that can be sent on an interface.
Port VLAN ID TLV PVID TLV.
Port And Protocol VLAN ID TLV Port and protocol VLAN ID TLV.
VLAN Name TLV VLAN name TLV.
Protocol Identity TLV Protocol ID TLV.
IEEE 802.3 extend TLV IEEE 802.3 organizational-specific TLVs that can be sent on an interface.
MAC-Physic TLV TLV indicating physical attributes of an interface.
Power Via MDI TLV Power capability TLV.
Link Aggregation TLV Link aggregation TLV.
Maximum Frame Size TLV Maximum frame length TLV.
LLDP-MED extend TLV LLDP MED TLV.
Capabilities TLV TLV indicating MED capability sets.
Extended Power Via MDI TLV TLV indicating the extended power supply capabilities.
Inventory TLV Inventory information, including Hardware Revision TLV, Firmware Revision TLV, Software Revision TLV, Serial Number TLV, Manufacturer Name TLV, Model name TLV, and Asset id TLV.
Network Policy TLV Network policy TLV.
Location Identification TLV Location ID TLV.
EEE TLV EEE capability TLV.

display snmp-agent trap feature-name lldptrap all

Function

The display snmp-agent trap feature-name lldptrap all command displays whether the switch is enabled to send traps of LLDP feature to the NMS.

Format

display snmp-agent trap feature-name lldptrap all

Parameters

None

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

Before running the display snmp-agent trap feature-name lldptrap all command, run the snmp-agent command to enable the SNMP Agent function.

Example

# Display whether the switch is enabled to send traps of LLDP feature to the NMS.

<HUAWEI> display snmp-agent trap feature-name lldptrap all
------------------------------------------------------------------------------  
Feature name: LLDPTRAP                                                          
Trap number : 5                                                                 
------------------------------------------------------------------------------  
Trap name                       Default switch status   Current switch status   
lldpRemTablesChange             on                      on                      
hwLldpEnabled                   on                      on                      
hwLldpDisabled                  on                      on                      
hwLldpLocManIPAddrChange        on                      on 
hwLldpRateExcessive             on                      on 
Table 16-39  Description of the display snmp-agent trap feature-name lldptrap all command output

Item

Description

Feature name

Name of the feature that generates traps.

Trap number

Number of traps generated by LLDP feature.

Trap name

Name of the trap. The LLDP feature supports the following traps:

  • lldpRemTablesChange: Sends a trap when LLDP neighbor information changes.
  • hwLldpEnabled: Sends a Huawei proprietary trap when the LLDP function is enabled globally.
  • hwLldpDisabled: Sends a Huawei proprietary trap when the LLDP function is disabled globally.
  • hwLldpLocManIPAddrChange: Sends a Huawei proprietary trap when the LLDP management address of the device changes.
  • hwLldpRateExcessive: Sends a Huawei proprietary trap when the rate of LLDPDUs received by an interface exceeds the trap threshold.

Default switch status

Default status of a trap:
  • on: The switch is enabled to send this trap to the NMS.
  • off: The switch is disabled to send this trap to the NMS.

Current switch status

Current status of a trap:
  • on: The switch is enabled to send this trap to the NMS.
  • off: The switch is disabled to send this trap to the NMS.

This status can be configured using the snmp-agent trap enable feature-name lldptrap command.

ip domain-name

Function

The ip domain-name command adds a suffix to a device name.

The undo ip domain-name command deletes the suffix of a device name.

By default, a device name does not have a suffix.

NOTE:

Only the S1720GFR, S1720GW, S1720GW-E, S1720GWR, S1720GWR-E, S1720X, S1720X-E, S2720EI, S2750EI, S5700LI, S5700S-LI, S5710-X-LI, S5720LI, S5720S-LI, S5720SI, S5720S-SI, S5730SI, S5730S-EI, S6720LI, S6720S-LI, S6720SI, and S6720S-SI support this command.

Format

ip domain-name domain-name

undo ip domain-name

Parameters

Parameter Description Value
domain-name Specifies the suffix of a device name. The value is a string of 1 to 255 characters without spaces. It contains digits, letters, hyphens (-), underscores (_), and dots (.).

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

A device name and a suffix form a fully qualified domain name (FQDN). If you need to add a suffix to a device name, run the ip domain-name command. In this situation, the System Name TLV in an LLDP packet is in "device name.suffix" format. For example, if the device name is HUAWEI and suffix is area1, the System Name TLV in an LLDP packet is HUAWEI.area1.

Precautions

If you run this command multiple times, only the latest configuration takes effect.

Example

# Set the device name suffix to area1.

<HUAWEI> system-view
[HUAWEI] ip domain-name area1

lldp auto-vlan sensor ap

Function

The lldp auto-vlan sensor ap command configures a switch to identify Huawei fit APs using LLDP and adds the interfaces receiving the LLDP packets from APs to the specified VLAN.

The undo lldp auto-vlan command disables this function.

By default, this function is disabled.

Format

lldp auto-vlan vlan-id sensor ap

undo lldp auto-vlan

Parameters

Parameter

Description

Value

vlan-id

Indicates the VLAN to which the interfaces receiving LLDP packets from APs are added.

The value is an integer that ranges from 1 to 4094.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

When a switch is connected to Huawei fit APs, the interfaces connected to APs must be added to the AP's management VLAN in untagged mode. If many APs are connected to the switch, the configuration is complex. To facilitate operation, run the lldp auto-vlan vlan-id sensor ap command to enable the switch to automatically add the interfaces receiving LLDP packets from APs to the AP's management VLAN in untagged mode.

Prerequisites

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

Precautions

The VLAN specified in the command can be an existing VLAN or created after this command is executed, but cannot be the control VLAN for SEP/RRPP/ERPS.

After an interface receiving LLDP packets is added to the specified VLAN, the PVID on the interface becomes invalid. To view VLAN information on the interfaces, run the display port vlan [ interface interface-number | active ] command. After the LLDP neighbor relationships on the interfaces are aged out (for example, the APs go offline), the original PVIDs become valid.

Example

# Add the interfaces receiving LLDP packets from Huawei fit APs to VLAN 100.

<HUAWEI> system-view
[HUAWEI] vlan 100
[HUAWEI-vlan100] quit
[HUAWEI] lldp enable
[HUAWEI] lldp auto-vlan 100 sensor ap

lldp clear neighbor

Function

The lldp clear neighbor command clears LLDP neighbors in the system or on an interface of the device.

Format

lldp clear neighbor [ interface interface-type interface-number ]

Parameters

Parameter

Description

Value

interface interface-type interface-number

Indicates the type and number of the interface whose LLDP neighbors to be cleared. In the command:
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If no interface is specified, this command clears LLDP neighbors on all interfaces.

-

Views

User view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

If you want to obtain the latest LLDP neighbor information of interfaces, use the lldp clear neighbor command to clear existing LLDP neighbors. When an interface receives new LLDP packets, new LLDP neighbors are generated.

Prerequisites

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

Example

# Clear LLDP neighbors of all interfaces.

<HUAWEI> lldp clear neighbor
Warning: This command will clear the neighbor information of all the ports. Continue? [Y/N]:y

lldp compliance cdp receive

Function

The lldp compliance cdp receive command enables CDP-compatible LLDP on an interface.

The undo lldp compliance cdp receive command disables CDP-compatible LLDP on an interface.

By default, CDP-compatible LLDP is disabled on an interface.

Format

lldp compliance cdp receive

undo lldp compliance cdp receive

Parameters

None

Views

MEth interface view, Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

Neighbors may use other proprietary protocols but LLDP, for example, CDP. To ensure that the local device can discover and identify the neighbors, you can use this command to enable CDP-compatible LLDP on an interface.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

An Ethernet interface supports this command no matter whether it works in Layer 2 or Layer 3 mode.

Example

# Enable CDP-compatible LLDP on GigabitEthernet0/0/1.

<HUAWEI> system-view
[HUAWEI] interface GigabitEthernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp compliance cdp receive

lldp compliance cdp txrx

Function

The lldp compliance cdp txrx command enables an interface to exchange information with CDP-capable devices.

The undo lldp compliance cdp txrx command disables an interface from exchanging information with CDP-capable devices.

By default, an interface cannot exchange information with CDP-capable devices.

Format

lldp compliance cdp txrx

undo lldp compliance cdp txrx

Parameters

None

Views

MEth interface view, Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

Some IP phones send proprietary protocol packets but not DHCP packets to apply for IP addresses. After you run the lldp compliance cdp txrx command on an interface, the switch can identify proprietary protocol packets sent from such the IP phone connected to the interface and respond to the proprietary protocol packets. In addition, the switch assigns the voice VLAN configured on the LLDP module to the IP phone.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

An Ethernet interface supports this command no matter whether it works in Layer 2 or Layer 3 mode.

When a switch connects the IP phones of some vendors, you are advised to run the lldp tlv-enable med-tlv network-policy voice-vlan vlan vlan-id command to specify the voice VLAN ID in the MED TLVs advertised from the interface.

Example

# Enable GigabitEthernet0/0/1 to exchange information with CDP-capable voice devices.

<HUAWEI> system-view
[HUAWEI] interface GigabitEthernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp tlv-enable med-tlv network-policy voice-vlan vlan 10
[HUAWEI-GigabitEthernet0/0/1] lldp compliance cdp txrx

lldp dot3-tlv power

Function

The lldp dot3-tlv power command sets the standard to which the 802.3 Power Via MDI TLV sent by an interface conforms.

The undo lldp dot3-tlv power command restores the default configuration.

By default, the 802.3 Power Via MDI TLV conforms to 802.1 ab.

Format

lldp dot3-tlv power { 802.1ab | 802.3at }

undo lldp dot3-tlv power 802.3at

Parameters

Parameter

Description

Value

802.1ab

Indicates that the 802.3 Power Via MDI TLV sent by the interface conforms to 802.1 ab.

-

802.3at

Indicates that the 802.3 Power Via MDI TLV sent by the interface conforms to 802.3 at.

-

Views

Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

The 802.3 Power Via MDI TLV has the following formats:
  • 802.1 ab format: [ TLV type | TLV information string length | 802.3 OUI | MDI power support | PSE power pair | power class ]
  • 802.3 at format: [ TLV type | TLV information string length | 802.3 OUI | MDI power support | PSE power pair | power class | type/source/priority | PD requested power value | PSE allocated power value ]
Based on 802.1 ab, 802.3 at extends three fields: type/source/priority, PD requested power value, and PSE allocated power value.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

Before selecting a format of the 802.3 Power via MDI TLV, you must know the TLV format supported by the neighbors. The TLV format on the local device must be the same as that on the neighbors. You are advised to retain the default configuration of the switch. That is, interfaces send 802.3 Power via MDI TLV conforming to 802.1 ab. The switch can then adapt to 802.3 Power via MDI TLV conforming to 802.1ab or 802.3at based on the remote device and correctly communicates with the remote device.

An Ethernet interface supports the lldp dot3-tlv power command no matter whether it works in Layer 2 or Layer 3 mode.

Example

# Configure the interface to send the 802.3 Power Via MDI TLV conforming to 802.3 at.

<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp dot3-tlv power 802.3at

lldp enable (interface view)

Function

The lldp enable command enables LLDP on an interface.

The undo lldp enable command disables LLDP on an interface.

After LLDP is enabled in the system view, all interfaces are enabled with LLDP.

Format

lldp enable

undo lldp enable

Parameters

None

Views

MEth interface view, Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

After LLDP is enabled on an interface, the interface exchanges LLDP packets with LLDP-enabled neighbors. The interface receives status information from the neighbors and sends the local status information to the neighbors. The NMS then obtains the status information for topology discovery.

Prerequisites

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

Precautions

LLDP can be enabled in the system view and the interface view.
  • After LLDP is enabled in the system view, all interfaces are enabled with LLDP.
  • After LLDP is disabled in the system view, all LLDP settings are restored to the default settings except the setting of LLDP trap. Therefore, LLDP is also disabled on all interfaces.
  • An interface can send and receive LLDP packets only after LLDP is enabled in both the system view and the interface view.
  • After LLDP is disabled globally, the commands for enabling and disabling LLDP on an interface do not take effect.
  • If LLDP needs to be disabled on some interfaces, enable LLDP globally first, and run the undo lldp enable command on these interfaces. To re-enable LLDP on these interfaces, run the lldp enable command in the views of these interfaces.

The lldp enable (interface view) command can be executed only on an Ethernet interface, regardless of whether it works at Layer 2 or Layer 3 mode, but not on a logical interface such as a VLANIF or Eth-Trunk interface. For an Eth-Trunk interface, LLDP can only be enabled on its member interfaces. LLDP-enabled interfaces and LLDP-disabled interfaces can exist in the same Eth-Trunk.

Example

# Disable LLDP on GigabitEthernet0/0/1.

<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] undo lldp enable

lldp enable (system view)

Function

The lldp enable command enables LLDP globally.

The undo lldp enable command disables LLDP globally.

By default, LLDP is enabled globally.

Format

lldp enable

undo lldp enable

Parameters

None

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

To view the Layer 2 link status or analyze network topology, run the lldp enable command.

Configuration Impact

After LLDP is enabled globally, the device sends its own status information to LLDP-enabled neighbors and receives the status information from the neighbors.

Precautions

After the global LLDP is disabled, the LLDP configuration is deleted from all interfaces.

The interval between enabling LLDP globally and disabling LLDP cannot be shorter than 10 seconds; otherwise, an error message is displayed.

LLDP can be enabled in the system view and the interface view.
  • After LLDP is enabled in the system view, all interfaces are enabled with LLDP.
  • After LLDP is disabled in the system view, all LLDP settings are restored to the default settings except the setting of LLDP trap. Therefore, LLDP is also disabled on all interfaces.
  • An interface can send and receive LLDP packets only after LLDP is enabled in both the system view and the interface view.
  • After LLDP is disabled globally, the commands for enabling and disabling LLDP on an interface do not take effect.
For the device running a version earlier than V200R011C10SPC200:
  • By default, LLDP is disabled globally, and the configuration file does not have the undo lldp enable configuration. After the device is upgraded to V200R011C10SPC200 or a later version, the configuration file has the undo lldp enable configuration.
  • If lldp enable has been executed to enable LLDP globally, the configuration file has the lldp enable configuration. After the device is upgraded to V200R011C10SPC200 or a later version, the configuration file no longer has the lldp enable configuration.
The status of global LLDP does not change after the device is upgraded.

Example

# Enable LLDP globally.

<HUAWEI> system-view
[HUAWEI] lldp enable

# Disable LLDP globally.

<HUAWEI> system-view
[HUAWEI] undo lldp enable
Warning: This command will delete the configurations of LLDP on all the ports.Continue?[Y/N]:y

lldp management-address

Function

The lldp management-address command configures the LLDP management IP address.

The undo lldp management-address command restores the default setting.

By default, the system automatically obtains the management IP address.

Format

lldp management-address ip-address

undo lldp management-address

Parameters

Parameter

Description

Value

ip-address

Specifies the management IP address.

The value is in dotted decimal notation.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

The management IP address is carried in the management address TLV field of the LLDP packet. It is used by the NMS to identify and manage devices. A management address identifies a device, facilitating the layout of the network topology and network management. To allocate a management address to a neighbor, run the lldp management-address command.

Prerequisites

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

The management IP address to be allocated must be a valid unicast IP address existing on the device. And the interface configured with the IP address must not be bound to any VPN instance.

Configuration Impact

After the configuration, the management IP address is added to the management address TLV field of the LLDP packet. The NMS then identifies the device according to the management IP address.

Precautions

If no management address is configured or an invalid management address is configured, the system sets an IP address in the address list as the management address. The system selects the IP address in the following sequence: loopback interface address, management port address, VLANIF interface address, VBDIF interface address, Layer 3 Ethernet interface address, and Sub-interface. Among the IP addresses of the same type, the system selects the smallest one. If the system fails to find a management IP address, the bridge MAC address is used as the management address.

Example

# Set the LLDP management IP address to 10.10.10.1.

<HUAWEI> system-view
[HUAWEI] lldp management-address 10.10.10.1

lldp message-transmission delay

Function

The lldp message-transmission delay command sets the LLDP packet transmission delay.

The undo lldp message-transmission delay command restores the default LLDP packet transmission delay.

By default, the LLDP packet transmission delay is 2 seconds.

Format

lldp message-transmission delay delay

undo lldp message-transmission delay [ delay ]

Parameters

Parameter

Description

Value

delay

Specifies the LLDP packet transmission delay.

The value is an integer ranging from 1 to 8192, in seconds. The default value is 2 seconds.

The delay value depends on the interval value in lldp message-transmission interval. The delay value must be equal to or smaller than a quarter of the interval value.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

There is a delay before the interface sends an LLDP packet to the neighbor when the device status changes frequently. After the LLDP packet transmission delay is set on the device, the LLDP-enabled interfaces send LLDP packets to neighbors after a delay (the delay is the same as or longer than the delay you specified). The interfaces may send LLDP packets at different time points.

If the device status changes frequently, extend the delay in preventing the device from frequently sending packets to the neighbors. A delay suppresses the network topology flapping.

Prerequisites

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

Configuration Impact

The LLDP packet transmission delay must be set properly and adjusted according to network loads.

  • A large value reduces the LLDP packet transmission frequency when the local device status frequently changes. This helps save system resources. However, if the value is too large, the device cannot notify neighbors of its status in a timely manner, and the NMS cannot discover the network topology changes in real time.
  • A small value increases the LLDP packet transmission frequency and enables the NMS to discover network topology changes in real time when the local device status frequently changes. However, if the value is too small, LLDP packets are exchanged frequently, increasing the system load.
  • The default value is recommended.

Precautions

Consider the value of interval when adjusting the value of delay because it is restricted by the value of interval.
  • The value of delay ranges from 1 to 8192.
  • The value of delay must be smaller than or equal to a quarter of interval. Therefore, if you want to set delay to be greater than a quarter of interval, first increase the interval value to four times the new delay value, and then increase the delay value.
NOTE:

If the interval value is smaller than four times the delay value, the system displays an error message when you run the undo lldp message-transmission delay command. To run the undo lldp message-transmission delay command in this case, increase the interval value to at least four times the delay value first.

Example

# Set the LLDP packet transmission delay to 5 second.

<HUAWEI> system-view
[HUAWEI] lldp message-transmission delay 5

lldp message-transmission hold-multiplier

Function

The lldp message-transmission hold-multiplier command sets the hold time multiplier of device information stored on neighbors.

The undo lldp message-transmission hold-multiplier command restores the default hold time multiplier of device information stored on neighbors.

The default hold time multiplier is 4.

Format

lldp message-transmission hold-multiplier hold

undo lldp message-transmission hold-multiplier [ hold ]

Parameters

Parameter

Description

Value

hold

Specifies the hold time multiplier of device information on neighbors.

The value is an integer ranging from 2 to 10. The default value is 4.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

The time multiplier is used to calculate how long a packet can be saved on a neighboring node. After receiving an LLDP packet, a neighbor updates the aging time of the device information from the sender based on the TTL.

The storage time calculation formula is: TTL = Min (65535, (interval x hold)).

TTL is the device information storage time. It is the smaller value between 65535 and (interval x hold).

interval indicates the interval at which the device sends LLDP packets to neighbors. This parameter is set by lldp message-transmission interval. hold indicates the hold time multiplier of device information on neighbors.

After the LLDP function is disabled on the device, its neighbors wait until the TTL of the device information expires, and then delete the device information. This prevents network topology flapping.

Prerequisites

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

Configuration Impact

The hold time multiplier of device information on neighbors must be set to a proper value.
  • A large value of hold prevents network topology flapping. However, if the value is too large, the device cannot notify neighbors of its status in a timely manner, and the NMS cannot discover the network topology changes in real time.
  • A small value of hold enables the NMS to discover topology change in time. However, if the value is too small, the neighbors update device information too frequently. This increases the load on the system and wastes resources.
  • The default value is recommended.

Example

# Set the hold time multiplier of device information on neighbors to 5.

<HUAWEI> system-view
[HUAWEI] lldp message-transmission hold-multiplier 5

lldp message-transmission interval

Function

The lldp message-transmission interval command sets the LLDP transmission interval.

The undo lldp message-transmission interval command restores the default LLDP transmission interval.

The default LLDP transmission interval is 30 seconds.

Format

lldp message-transmission interval interval

undo lldp message-transmission interval [ interval ]

Parameters

Parameter

Description

Value

interval

Specifies the LLDP transmission interval.

The value is an integer ranging from 5 to 32768, in seconds. The default value is 30 seconds.

The interval value depends on the delay value in lldp message-transmission delay. The value of interval must be equal to or greater than four times the value of delay. Otherwise, an error occurs in the configuration.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

When the LLDP status of the device keeps unchanged or the device does not discover new neighbors, the interface sends LLDP packets to the neighbors at a certain interval. After the LLDP transmission interval is set on the device, the LLDP enabled interfaces send LLDP packets to neighbors at this interval. The interfaces may send LLDP packets at different time points.

If you want to change the network topology detection frequency, run the lldp message-transmission interval command to change the LLDP transmission interval.

Prerequisites

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

Configuration Impact

The LLDP transmission interval must be set properly and adjusted according to network loads.
  • A large value reduces the LLDP packet transmission frequency. This helps save system resources. However, if the value is too large, the device cannot notify neighbors of its status in a timely manner, and the NMS cannot discover the network topology changes in real time.
  • A short interval increases the LLDP packet transmission frequency and enables the NMS to discover network topology changes in real time. However, if the interval is too short, LLDP packets are exchanged frequently, increasing the system load.

Precautions

Consider the value of delay when adjusting the value of interval because it is restricted by the value of delay.
  • The value of interval ranges from 5 to 32768.
  • The value of interval must be equal to or greater than four times the value of delay. Therefore, if you want to set interval to be smaller than four times the value of delay, first reduce the delay value to be equal to or smaller than a quarter of the new interval value, and then reduce the interval value.
NOTE:

If the delay value is greater than a quarter of the interval value, the system displays an error message when you run the undo lldp message-transmission interval command. To run the undo lldp message-transmission interval command in this case, reduce the delay value to be equal to or smaller than a quarter of interval first.

Example

# Set the LLDP transmission interval to 35 seconds.

<HUAWEI> system-view
[HUAWEI] lldp message-transmission interval 35

lldp restart-delay

Function

The lldp restart-delay command sets the delay in re-enabling the LLDP function on an interface.

The undo lldp restart-delay command restores the default delay in re-enabling the LLDP function on an interface.

The default delay is 2 seconds.

Format

lldp restart-delay delay

undo lldp restart-delay [ delay ]

Parameters

Parameter

Description

Value

delay

Specifies the delay in re-enabling the LLDP function on an interface.

The value is an integer ranging from 1 to 10, in seconds. The default value is 2 seconds.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

There is a delay before LLDP is re-enabled on an interface. The delay suppresses the topology flapping caused by the frequent LLDP status changes.

Prerequisites

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

Configuration Impact

The delay in re-enabling the LLDP function on an interface must be set properly.
  • A large value of delay prevents network topology flapping. However, if the value is too large, the device cannot notify neighbors of its status in a timely manner, and the NMS cannot discover the network topology changes in real time.
  • A small value of delay enables the NMS to discover topology change in time. However, if the value is too small, the neighbors update device information too frequently. This increases the load on the system and wastes resources.
  • The default value is recommended.

Example

# Set the delay in re-enabling the LLDP function on an interface to 3 second.

<HUAWEI> system-view
[HUAWEI] lldp restart-delay 3

lldp tlv-enable (MEth interface view)

Function

The lldp tlv-enable command sets the TLVs that can be sent by the MEth interface.

The undo lldp tlv-enable command sets the TLVs disabled on the MEth interface.

By default, the MEth interface can advertise all TLVs except the Location Identification TLV.

Format

lldp tlv-enable basic-tlv { all | management-address | port-description | system-capability | system-description | system-name }

lldp tlv-enable med-tlv { all | capability | inventory | location-id { civic-address device-type country-code { ca-type ca-value } & <1-10> | elin-address Tel-Number } }

undo lldp tlv-enable basic-tlv { all | management-address | port-description | system-capability | system-description | system-name }

undo lldp tlv-enable med-tlv { all | capability | inventory | location-id [ civic-address | elin-address ] }

Parameters

Parameter

Description

Value

all

Indicates to advertise all basic TLV.

-

management-address

Indicates to advertise Management-address TLV.

-

port-description

Indicates to advertise Port Description TLV.

-

system-capability

Indicates to advertise System Capabilities TLV.

-

system-description

Indicates to advertise System Description TLV.

-

system-name

Indicates to advertise System Name TLV.

-

all

Indicates to advertise all MED TLVs except the Location Identification TLV.

-

capability

Indicates to advertise MED Capabilities TLV.

-

inventory

Indicates to advertise Hardware Revision TLV, Firmware Revision TLV, Software Revision TLV, Serial Number TLV, Manufacturer Name TLV, Model Name TLV, and Asset ID TLV.

-

location-id

Indicates to advertise Location Identification TLV.

-

civic-address device-type country-code { ca-type ca-value } & <1-10>

Indicates to advertise the common address information of the network devices encapsulated in Location Identification TLV.
  • device-type specifies the type of the device. The value is an integer that ranges from 0 to 2. 0 indicates that the device is a DHCP server. 1 indicates that the device is a switch. 2 indicates that the device is an MED endpoint.
  • country-code specifies the country code. For the value range, see ISO 3166.
  • { ca-type ca-value }&<1-10> specifies the address information. ca-type specifies the type of address information. The value is an integer that ranges from 0 to 255. ca-value specifies the content of the address information. The value is a string of 1-250 characters. <1-10> indicates that the preceding parameters can be entered 10 times.

-

elin-address Tel-Number

Advertises the emergency phone number encapsulated in Location Identification TLV.

The value is a string of 10 to 25 numerals. Each numeral ranges from 0 to 9.

Views

MEth interface view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

In LLDP, all device information is encapsulated in Link Layer Discovery Protocol data units (LLDPDUs), which are then sent to neighbors. An LLDPDU contains a variety of TLVs. In a TLV, T indicates the information type, L indicates the information length, and V indicates the value or the content to be sent.

Devices exchange LLDPDUs carrying TLVs to obtain neighbor information. LLDPPDUs supported by the management interface includes basic TLVs and MED TLVs.

Devices on both ends can have different TLV types configured. You only need to configure TLV types according to networking requirements.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

  • If the all parameter is not specified, all the available TLVs of the specified type can be advertised except the Location Identification TLV. If the all parameter is not specified, only one type of TLV can be advertised. To advertise multiple types of TLVs, run this command multiple times.

  • You can specify the other types of MED TLVs only after specifying the MED Capabilities TLV.

    To disable the MED Capabilities TLV, first disable the other types of MED TLVs.

Example

# Configure The MEth interface to advertise the MED Capabilities TLV.

<HUAWEI> system-view
[HUAWEI] interface meth 0/0/1
[HUAWEI-MEth0/0/1] lldp tlv-enable med-tlv capability

lldp tlv-enable basic-tlv

Function

The lldp tlv-enable basic-tlv command sets the basic TLVs that can be sent by an interface.

The undo lldp tlv-enable basic-tlv command set the basic TLVs disabled on an interface.

By default, an interface can advertise all basic TLVs.

Format

lldp tlv-enable basic-tlv { all | management-address | port-description | system-capability | system-description | system-name }

undo lldp tlv-enable basic-tlv { all | management-address | port-description | system-capability | system-description | system-name }

Parameters

Parameter

Description

Value

all

Indicates to advertise all basic TLVs.

-

management-address

Indicates to advertise Management-address TLV.

-

port-description

Indicates to advertise Port Description TLV.

-

system-capability

Indicates to advertise System Capabilities TLV.

-

system-description

Indicates to advertise System Description TLV.

-

system-name

Indicates to advertise System Name TLV.

-

Views

Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

In LLDP, all device information is encapsulated in Link Layer Discovery Protocol data units (LLDPDUs), which are then sent to neighbors. An LLDPDU contains a variety of TLVs. In a TLV, T indicates the information type, L indicates the information length, and V indicates the value or the content to be sent.

Devices exchange LLDPDUs carrying TLVs to obtain neighbor information. The TLVs that can be encapsulated in an LLDP packet include basic TLVs, TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Basic TLVs are essential for managing network devices. The TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs are defined by standardization organizations and other organizations, which are used to enhance the network device management. You can determine whether to advertise the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Devices on both ends can have different TLV types configured. You only need to configure TLV types according to networking requirements.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

If the all parameter is not specified, only one type of TLV can be advertised. To advertise multiple types of TLVs, run this command multiple times.

An Ethernet interface supports this command no matter whether it works in Layer 2 or Layer 3 mode.

Example

# Configure GigabitEthernet0/0/1 to advertise all basic TLVs.

<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp tlv-enable basic-tlv all

lldp tlv-enable dot1-tlv

Function

The lldp tlv-enable dot1-tlv command sets to advertise TLVs defined by the IEEE 802.1 working group.

The undo lldp tlv-enable dot1-tlv command sets the TLVs defined by the IEEE 802.1 working group disabled on an interface.

By default, an interface advertises all TLVs defined by the IEEE 802.1 working group, except Protocol Identity TLV.

Format

lldp tlv-enable dot1-tlv { all | port-vlan-id | protocol-vlan-id [ vlan-id ] | vlan-name [ vlan-id ] | protocol-identity }

undo lldp tlv-enable dot1-tlv { all | port-vlan-id | protocol-vlan-id [ vlan-id ] | vlan-name [ vlan-id ] | protocol-identity }

Parameters

Parameter Description Value
all Indicates to advertise all TLVs defined by the IEEE 802.1 working group. -
port-vlan-id Indicates to advertise Port VLAN ID TLV. The VLAN ID is the default VLAN ID on the interface. -
protocol-vlan-id [ vlan-id ] Indicates to advertise Port And Protocol VLAN ID TLV. If vlan-id is not specified, the interface does not support protocol VLAN TLVs. The value of vlan-id is an integer that ranges from 1 to 4094.
vlan-name [ vlan-id ] Indicates to advertise VLAN Name TLV. If vlan-id is not specified, the default VLAN ID is used. The value of vlan-id is an integer that ranges from 1 to 4094.
protocol-identity Indicates to advertise Protocol Identity TLV. -

Views

Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

In LLDP, all device information is encapsulated in Link Layer Discovery Protocol data units (LLDPDUs), which are then sent to neighbors. An LLDPDU contains a variety of TLVs. In a TLV, T indicates the information type, L indicates the information length, and V indicates the value or the content to be sent.

Devices exchange LLDPDUs carrying TLVs to obtain neighbor information. The TLVs that can be encapsulated in an LLDP packet include basic TLVs, TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Basic TLVs are essential for managing network devices. The TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs are defined by standardization organizations and other organizations, which are used to enhance the network device management. You can determine whether to advertise the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Devices on both ends can have different TLV types configured. You only need to configure TLV types according to networking requirements.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

If the all parameter is not specified, only one type of TLV can be advertised. To advertise multiple types of TLVs, run this command multiple times.

NOTE:

An Ethernet interface working in Layer 3 mode does not support the TLVs defined in IEEE802.1.

Example

# Configure GigabitEthernet0/0/1 to advertise the port VLAN TLV in the IEEE 802.1 format.
<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp tlv-enable dot1-tlv port-vlan-id

lldp tlv-enable dot3-tlv

Function

The lldp tlv-enable dot3-tlv command sets to advertise the TLVs defined by the IEEE 802.3 working group.

The undo lldp tlv-enable dot3-tlv command sets the TLVs defined by the IEEE 802.3 working group disabled on an interface.

By default, an interface advertises all TLVs defined by the IEEE 802.3 working group.

Format

lldp tlv-enable dot3-tlv { all | eee | link-aggregation | mac-physic | max-frame-size | power }

undo lldp tlv-enable dot3-tlv { all | eee | link-aggregation | mac-physic | max-frame-size | power }

Parameters

Parameter

Description

Value

all

Indicates to advertise all TLVs defined by the IEEE 802.3 working group.

-

eee

Indicates to advertise EEE (Energy Efficient Ethernet) TLV.

EEE is supported only when the switch has only one neighbor.

-

link-aggregation

Indicates to advertise Link Aggregation TLV.

-

mac-physic

Indicates to advertise MAC/PHY Configuration/Status TLV.

-

max-frame-size

Indicates to advertise Maximum Frame Size TLV.

-

power

Indicates to advertise Power Via MDI TLV.

-

Views

Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

In LLDP, all device information is encapsulated in Link Layer Discovery Protocol data units (LLDPDUs), which are then sent to neighbors. An LLDPDU contains a variety of TLVs. In a TLV, T indicates the information type, L indicates the information length, and V indicates the value or the content to be sent.

Devices exchange LLDPDUs carrying TLVs to obtain neighbor information. The TLVs that can be encapsulated in an LLDP packet include basic TLVs, TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Basic TLVs are essential for managing network devices. The TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs are defined by standardization organizations and other organizations, which are used to enhance the network device management. You can determine whether to advertise the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Devices on both ends can have different TLV types configured. You only need to configure TLV types according to networking requirements.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

If the all parameter is not specified, only one type of TLV can be advertised. To advertise multiple types of TLVs, run this command multiple times.

An Ethernet interface supports this command no matter whether it works in Layer 2 or Layer 3 mode.

Example

# Configure GigabitEthernet0/0/1 to advertise the Link Aggregation TLV in the IEEE 802.3 format.

<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp tlv-enable dot3-tlv link-aggregation

lldp tlv-enable med-tlv

Function

The lldp tlv-enable med-tlv command sets to advertise the MED TLVs.

The undo lldp tlv-enable med-tlv command sets the MED TLVs disabled on an interface.

By default, an interface advertises all types of MED TLVs except the Location Identification TLV and Network Policy TLV.

NOTE:

Although the interface does not advertise Network Policy TLV, Network Policy TLV is still enabled.

Format

lldp tlv-enable med-tlv { all | capability | inventory | location-id { civic-address device-type country-code { ca-type ca-value } &<1-10> | elin-address Tel-Number } | network-policy [ voice-vlan { vlan vlan-id [ cos cvalue | dscp dvalue ]* | 8021p [ cos cvalue | dscp dvalue ]* | untagged } ] | power-over-ethernet }

undo lldp tlv-enable med-tlv { all | capability | inventory | location-id [ civic-address | elin-address ] | network-policy [ voice-vlan { vlan | cos | dscp | 8021p | untagged } ] | power-over-ethernet }

Parameters

Parameter

Description

Value

all

Indicates that all MED TLVs except Location Identification TLV and Network Policy TLV are advertised.

NOTE:

After the all parameter is specified, the Network Policy TLV is enabled, but not advertised.

-

capability

Indicates to advertise MED Capabilities TLV.

-

inventory

Indicates to advertise Hardware Revision TLV, Firmware Revision TLV, Software Revision TLV, Serial Number TLV, Manufacturer Name TLV, Model Name TLV, and Asset ID TLV.

-

location-id

Indicates to advertise Location Identification TLV.

-

civic-address device-type country-code { ca-type ca-value } & <1-10>

Indicates to advertise the common address information of the network devices encapsulated in Location Identification TLV.
  • device-type specifies the type of the device. The value is an integer that ranges from 0 to 2. 0 indicates that the device is a DHCP server. 1 indicates that the device is a switch. 2 indicates that the device is an MED endpoint.
  • country-code specifies the country code. For the value range, see ISO 3166.
  • { ca-type ca-value }&<1-10> specifies the address information. ca-type specifies the type of address information. The value is an integer that ranges from 0 to 255. ca-value specifies the content of the address information. The value is a string of 1-250 characters. <1-10> indicates that the preceding parameters can be entered 10 times.

-

elin-address Tel-Number

Advertises the emergency phone number encapsulated in Location Identification TLV.

The value is a string of 10 to 25 numerals. Each numeral ranges from 0 to 9.

network-policy

Advertises Network Policy TLV.

Network Policy TLV is used to exchange VLAN configurations between network devices and terminal devices. A switch uses the TLV to advertise voice VLAN ID and voice stream priority to an IP phone. Then the IP phone forwards packets according to the received voice VLAN ID and priority, ensuring the voice quality.

NOTE:
An Ethernet interface working in Layer 3 mode does not support the Network Policy TLV.

-

voice-vlan

Encapsulates the voice VLAN ID when advertising Network Policy TLV.

-

vlan vlan-id

Specifies the voice VLAN ID.

The value is an integer that ranges from 1 to 4094.

cos cvalue

Specifies the CoS priority.

The CoS priority is the PRI (Priority) field in an 802.1Q VLAN frame. This field is 3 bits long and ensures that high-priority data packets are forwarded first when congestion occurs.

The value is an integer that ranges from 0 to 7. The default value is 5. A larger value indicates a higher priority.

dscp dvalue

Sets the DSCP priority.

The first six bits of the Type of Service (ToS) field in an IPv4 packet header are used as the DiffServ Code Point (DSCP). DSCP is used in the DiffServ model to provide QoS guarantee on an IP network. The operations performed by the traffic controller on the gateway are determined only by these six bits.

The value is an integer that ranges from 0 to 63. The default value is 46.

8021p

Sets the voice VLAN ID to VLAN 0.

-

untagged

Configures voice devices to send untagged voice data packets.

-

power-over-ethernet

Advertises Extended Power via MDI TLV.

-

Views

Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 40GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

In LLDP, all device information is encapsulated in Link Layer Discovery Protocol data units (LLDPDUs), which are then sent to neighbors. An LLDPDU contains a variety of TLVs. In a TLV, T indicates the information type, L indicates the information length, and V indicates the value or the content to be sent. Devices exchange LLDPDUs carrying TLVs to obtain neighbor information. The TLVs that can be encapsulated in an LLDP packet include basic TLVs, TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs. Basic TLVs are essential for managing network devices. The TLVs in the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs are defined by standardization organizations and other organizations, which are used to enhance the network device management. You can determine whether to advertise the IEEE 802.1 format, TLVs in the IEEE 802.3 format, and MED TLVs.

Devices on both ends can have different TLV types configured. You only need to configure TLV types according to networking requirements.

Prerequisites

  1. LLDP has been enabled globally using the lldp enable (system view) command.
  2. LLDP has been enabled on the interface using the lldp enable (interface view) command.

Precautions

  • When the supported TLVs are MED TLVs, the lldp tlv-enable command with the all parameter advertises all TLVs except Location Identification TLV. If the all parameter is not specified, only one type of TLV can be advertised. To advertise multiple types of TLVs, run this command multiple times.

  • You can specify the other types of MED TLVs only after specifying the MED Capabilities TLV. To disable the MED Capabilities TLV, first disable the other types of MED TLVs.
  • To disable the 802.3 MAC/PHY Configuration/Status TLVs, first disable the MED Capabilities TLV.
  • The 802.3 MAC/PHY Configuration/Status TLVs are automatically advertised after the MED Capabilities TLV is advertised.
  • If you disable the MED TLVs using the command with the all parameter, the 802.3 MAC/PHY Configuration/Status TLVs are not disabled automatically.
  • When the switch detects that the LLDP packet sent by an LLDP neighbor on an interface contains any type of MED TLV, the switch advertises all MED TLVs that can be advertised on the interface to the LLDP neighbor. However, the LLDP neighbor may support only parts of MED TLVs advertised by the switch, leading to an LLDP negotiation failure. You can run the undo lldp tlv-enable med-tlv command to enable the interface not to advertise the MED TLV that is not supported by the LLDP neighbor. For example, if a terminal does not support the 802.3af standard, that is, Extended Power-via-MDI TLV cannot be identified, run the undo lldp tlv-enable med-tlv power-over-ethernet command on the interface connected to the terminal to enable the interface not to advertise Extended Power-via-MDI TLV.

Example

# Configure GigabitEthernet0/0/1 to advertise the MED Capabilities TLV.

<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] lldp tlv-enable med-tlv capability

lldp trap-interval

Function

The lldp trap-interval command sets the delay in sending neighbor change traps to the NMS.

The undo lldp trap-interval command restores the default delay in sending neighbor change traps to the NMS.

By default, the device sends a neighbor change trap to the NMS after a 5-second delay.

Format

lldp trap-interval interval

undo lldp trap-interval [ interval ]

Parameters

Parameter

Description

Value

interval

Specifies the delay in sending traps.

The value is an integer ranging from 5 to 3600, in seconds. The default value is 5 seconds.

The default value is recommended.

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

There is a delay before the device sends LLDP traps about neighbor information changes to the NMS. When neighbor information changes frequently, you can prolong the delay. In this way, the device will not frequently send traps to the NMS, and the network topology flapping is suppressed.

Prerequisites

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

Configuration Impact

After the delay is set on the device, LLDP-enabled interfaces send LLDP traps to neighbors after a delay (the delay is the same as or longer than the delay you specified). The interfaces may send LLDP traps at different time points.

Precautions

The configured delay applies only to the trap, which reports changes in neighbor information, including the number of added neighbors, number of deleted neighbors, number of neighbors that are aged out, and number of neighbors of which the information is deleted.

Example

# Set the delay in sending neighbor change traps to 6 seconds.

<HUAWEI> system-view
[HUAWEI] lldp trap-interval 6

reset cdp statistics

Function

The reset cdp statistics command clears statistics about CDP packets that all interfaces receive and send or CDP packets that a specified interface receives and sends.

Format

reset cdp statistics [ interface interface-type interface-number ]

Parameters

Parameter Description Value
interface interface-type interface-number
Interface on which statistics about CDP packets are to be cleared.
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If this parameter is not specified, CDP packet information about all interfaces is cleared.

-

Views

User view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

If you want to quickly locate and process a CDP fault, you must calculate the numbers of CDP packets sent and received by a device for a specified period. Before collecting specific CDP packet statistics, you can run the reset cdp statistics command to clear existing statistics about CDP packets.

Prerequisites

LLDP has been globally enabled using the lldp enable command in the system view and LLDP has been configured to be compatible with CDP on interfaces using the lldp compliance cdp receive command.

Follow-up Procedure

After running the reset cdp statistics command to clear existing statistics about CDP packets, you can run the display cdp statistics command to check statistics about CDP packets sent and received by a device for a specific period.

Precautions

If you do not set the interface parameter when running the reset cdp statistics command, statistics about CDP packets sent and received by all interfaces are cleared. Exercise caution when running this command.

Example

# Display statistics about CDP packets that all interfaces receive and send.

<HUAWEI> reset cdp statistics

reset lldp statistics

Function

The reset lldp statistics command clears LLDP packet statistics on all interfaces or on a specified interface.

Format

reset lldp statistics [ interface interface-type interface-number ]

Parameters

Parameter

Description

Value

interface interface-type interface-number

Specifies the type and number of the interface where the LLDP statistics you want to reset. In the command:
  • interface-type specifies the interface type.
  • interface-number specifies the interface number.

If no interface is specified, LLDP packet statistics of all interfaces are cleared.

-

Views

User view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

To troubleshoot LLDP faults, you may need to view LLDP packet statistics within a certain period of time. In this case, you must run the reset lldp statistics command to clear existing LLDP packet statistics, and run the display lldp statistics command to view the new LLDP packet statistics.

Prerequisites

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

Example

# Clear LLDP packet statistics on all interfaces.

<HUAWEI> reset lldp statistics
Warning: This Command will clear LLDP statistics of all the ports. Continue? [Y/N]:y

# Clear LLDP packet statistics of GigabitEthernet0/0/1.

<HUAWEI> reset lldp statistics interface gigabitethernet 0/0/1

snmp-agent trap enable feature-name lldptrap

Function

The snmp-agent trap enable feature-name lldptrap command enables the LLDP trap function on the device.

The undo snmp-agent trap enable feature-name lldptrap command disables the LLDP trap function on the device.

By default, the LLDP trap function is enabled.

Format

snmp-agent trap enable feature-name lldptrap [ trap-name { hwlldpdisabled | hwlldpenabled | hwlldplocmanipaddrchange | hwlldprateexcessive | lldpremtableschange } ]

undo snmp-agent trap enable feature-name lldptrap [ trap-name { hwlldpdisabled | hwlldpenabled | hwlldplocmanipaddrchange | hwlldprateexcessive | lldpremtableschange } ]

Parameters

Parameter

Description

Value

trap-name

Enables or disables the trap function for the specified event.

-

hwlldpdisabled

Sends a Huawei proprietary trap when the LLDP function is disabled globally.

-

hwlldpenabled

Sends a Huawei proprietary trap when the LLDP function is enabled globally.

-

hwlldplocmanipaddrchange

Sends a Huawei proprietary trap when the LLDP management address of the device changes.

-

hwlldprateexcessive

Sends a Huawei proprietary trap when the rate of LLDPDUs received by an interface exceeds the alarm threshold.

The alarm threshold is 5. That is, a trap is sent if more than 5 LLDPDUs are received by an interface within one second.

-

lldpremtableschange

Sends a trap when LLDP neighbor information changes.

-

Views

System view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

To enable the device to send traps when the LLDP status changes, run the snmp-agent trap enable feature-name lldptrap command.

Prerequisites

A reachable route exists between the device and the NMS, and the SNMP parameters are set.

Configuration Impact

After the LLDP trap function is enabled, the device sends traps to the NMS in one of the following cases:
  • The LLDP function is enabled or disabled globally.
  • The local management address changes.
  • The rate of LLDPDUs received by an interface exceeds the alarm threshold.
  • A neighbor is added, deleted, discarded, or aged out.

Precautions

The LLDP trap function applies to all interfaces.

If the network topology is unstable, disable the LLDP trap function to prevent frequent trap sending.

To set the interval between sending neighbor change traps to the NMS, run the lldp trap-interval command. If neighbor information changes frequently, extend the interval to reduce the number of traps.

Example

# Enable the LLDP trap function on the device.

<HUAWEI> system-view
[HUAWEI] snmp-agent trap enable feature-name lldptrap
Translation
Download
Updated: 2019-10-21

Document ID: EDOC1000178165

Views: 48884

Downloads: 1171

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next