03-Layer 2 - LAN Switching Command Reference

HomeSupportResource CenterRoutersH3C SR8800 Series RoutersH3C SR8800Technical DocumentsCommandCommand ReferenceH3C SR8800 Command Reference-Release3347-6W10303-Layer 2 - LAN Switching Command Reference
10-LLDP Commands
Title Size Download
10-LLDP Commands 136.49 KB

LLDP configuration commands

display lldp local-information

Syntax

display lldp local-information [ global | interface interface-type interface-number ] [ | { begin | exclude | include } regular-expression ]

View

Any view

Default level

1: Monitor level

Parameters

global: Displays the global LLDP information.

interface interface-type interface-number: Specifies a port by its type and number.

|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.

begin: Displays the first line that matches the specified regular expression and all lines that follow.

exclude: Displays all lines that do not match the specified regular expression.

include: Displays all lines that match the specified regular expression.

regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.

Description

Use the display lldp local-information command to display the global LLDP information or the information contained in the LLDP TLVs to be sent to neighboring routers through a port.

If no keyword or argument is specified, this command displays all LLDP information to be sent, including the global LLDP information and the LLDP information about the LLDP-enabled ports.

Examples

# Display all LLDP information to be sent.

<Sysname> display lldp local-information

Global LLDP local-information:

  Chassis ID         : 00e0-fc00-9512

  System name        : H3C

  System description : H3C Comware software. H3C SR8800 Product Version SR8800-CMW520-A3300 Copyright (c) 2004-2010 Hangzhou H3C Tech. Co., Ltd. All rights reserve.

  System capabilities supported : Bridge,Router

  System capabilities enabled   : Bridge,Router

 

  MED information

  Device class: Connectivity device

 

  (MED inventory information of master board)

  HardwareRev               : Ver.B

  FirmwareRev               : 202

  SoftwareRev               : SR8800-CMW520-A3300

  SerialNum                 : NONE

  Manufacturer name         : H3C

  Model name                : SR02SRP1E3

  Asset tracking identifier : Unknown

LLDP local-information of port 157[GigabitEthernet3/1/1]:

  Port ID subtype  : Interface name

  Port ID          : GigabitEthernet3/1/1

  Port description : GigabitEthernet3/1/1 Interface

 

  Management address type           : ipV4

  Management address                : 192.168.2.200

  Management address interface type : IfIndex

  Management address interface ID   : 32

  Management address OID            : 0

 

  Port VLAN ID(PVID): 1000

 

  Port and protocol VLAN ID(PPVID) : 1000

  Port and protocol VLAN supported : No

  Port and protocol VLAN enabled   : No

 

  VLAN name of VLAN 1000: VLAN 1000

 

  Auto-negotiation supported : Yes

  Auto-negotiation enabled   : Yes

  OperMau                    : speed(100)/duplex(Full)

 

  PoE supported: No

 

 Link aggregation supported : Yes

  Link aggregation enabled   : No

  Aggregation port ID        : 0

 

  Maximum frame Size: 1552

 

  MED information

  Media policy type        : Unknown

  Unknown Policy           : Yes

  VLAN tagged              : No

  Media policy VlanID      : 0

  Media policy L2 priority : 0

  Media policy Dscp        : 0

LLDP local-information of port 158[GigabitEthernet3/1/2]:

  Port ID subtype  : Interface name

  Port ID          : GigabitEthernet3/1/2

  Port description : GigabitEthernet3/1/2 Interface

 

  Management address type           : ipv4

  Management address                : 192.168.1.100

  Management address interface type : IfIndex

  Management address interface ID   : 28

  Management address OID            : 0

 

  Port VLAN ID(PVID): 10

 

  Port and protocol VLAN ID(PPVID) : 10

  Port and protocol VLAN supported : No

  Port and protocol VLAN enabled   : No

 

  VLAN name of VLAN 10: VLAN 0010

 

  Auto-negotiation supported : Yes

  Auto-negotiation enabled   : Yes

  OperMau                    : speed(100)/duplex(Full)

 

  PoE supported: No

 

  Link aggregation supported : Yes

  Link aggregation enabled   : No

  Aggregation port ID        : 0

 

  Maximum frame Size: 1552

 

  MED information

  Media policy type        : Unknown

  Unknown Policy           : Yes

  VLAN tagged              : No

  Media policy VlanID      : 0

  Media policy L2 priority : 0

  Media policy Dscp        : 0

Table 1 Output description

Field

Description

Global LLDP local-information

The global LLDP information.

Chassis ID

Router MAC address.

System capabilities supported

Supported capabilities:

·       Bridge—Switching is supported.

·       Router—Routing is supported.

System capabilities enabled

Enabled capabilities:

·       Bridge—Switching is enabled.

·       Router—Routing is enabled.

Device class

MED device type.

HardwareRev

Hardware version.

FirmwareRev

Firmware version.

SoftwareRev

Software version.

LLDP local-information of port XX

LLDP information about a port.

Port ID subtype

Port ID type:

·       MAC address.

·       Interface name.

Management address interface type

Type of the interface identified by the management address.

Management address interface ID

ID of the interface identified by the management address.

Port and protocol VLAN supported

Indicates whether or not protocol VLAN is supported on the port.

Port and protocol VLAN enabled

Indicates whether or not protocol VLAN is enabled on the port.

Auto-negotiation supported

Indicates whether or not auto-negotiation is supported on the port.

Auto-negotiation enabled

Indicates whether or not auto-negotiation is enabled on the port.

OperMau

Speed and duplex state of the port.

PoE supported

Indicates whether or not PoE is supported.

Link aggregation supported

Indicates whether or not link aggregation is supported.

Link aggregation enabled

Indicates whether or not link aggregation is enabled.

Aggregation port ID

Aggregation group ID, which is 0 when link aggregation is disabled.

Media policy type

Media policy type:

·       Voice—The router is capable of processing voice data.

·       Unknown—The media policy is unknown.

Unknown Policy

The media policy is unknown.

VLAN tagged

Packets of the voice VLAN are tagged.

Media Policy VlanID

ID of the voice VLAN.

Media Policy L2 priority

Layer 2 priority.

Media Policy Dscp

DSCP precedence.

 

display lldp neighbor-information

Syntax

display lldp neighbor-information [ brief | interface interface-type interface-number [ brief ] | list [ system-name system-name ] ] [ | { begin | exclude | include } regular-expression ]

View

Any view

Default level

1: Monitor level

Parameters

brief: Displays the summary of LLDP information sent from the neighboring routers. If this keyword is not specified, this command displays detailed LLDP information sent from the neighboring routers.

interface interface-type interface-number: Displays the LLDP information sent from the neighboring routers received through a port specified by its type and number. If this option is not specified, this command displays the LLDP information sent from the neighboring routers received through all ports.

list: Displays the LLDP information sent from the neighboring routers in the form of a list.

system-name system-name: Displays the LLDP information sent from a neighboring router specified by its system name. The system-name argument is a character string of 1 to 255 characters. If this option is not specified, this command displays the LLDP information sent from all neighboring routers in a list.

|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.

begin: Displays the first line that matches the specified regular expression and all lines that follow.

exclude: Displays all lines that do not match the specified regular expression.

include: Displays all lines that match the specified regular expression.

regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.

Description

Use the display lldp neighbor-information command to display the LLDP information carried in LLDP TLVs sent from the neighboring routers.

Examples

# Display the LLDP information sent from the neighboring routers received through all ports.

<Sysname> display lldp neighbor-information

LLDP neighbor-information of port 573[GigabitEthernet5/1/1]:

  Neighbor index   : 1

  Update time      : 0 days,0 hours,11 minutes,56 seconds

  Chassis type     : MAC address

  Chassis ID       : 00e0-fc00-0000

  Port ID type     : Interface name

  Port ID          : GigabitEthernet5/1/1

  Port description : GigabitEthernet5/1/1 Interface

  System name        : H3C

  System description : H3C Comware software. H3C SR8800 Product Version SR8800-CMW520-A3300. Copyright (c) 2004-2010 Hangzhou H3C Tech. Co., Ltd. All rights reserved.

  System capabilities supported : Bridge,Router

  System capabilities enabled   : Bridge,Router

  Management address type           : ipV4

  Management address                : 127.0.0.1

  Management address interface type : IfIndex

  Management address interface ID   : Unknown

  Management address OID            : 0

 

  Port VLAN ID(PVID): 1

 

  Port and protocol VLAN ID(PPVID) : 1

  Port and protocol VLAN supported : No

  Port and protocol VLAN enabled   : No

 

  VLAN name of VLAN 1: VLAN 0001

 

  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               : Signal

  Port power classification : Class 0

 

  Link aggregation supported : Yes

  Link aggregation enabled   : No

  Aggregation port ID        : 0

 

  Maximum frame Size: 1552

Table 2 Output description

Field

Description

LLDP neighbor-information of port XX

LLDP information received through the port.

Update time

Time when LLDP information about a neighboring router was last updated.

Chassis type

Chassis information:

·       Chassis component.

·       Interface alias.

·       Port component.

·       MAC address.

·       Network address (IPv4).

·       Interface name.

·       Locally assigned—Indicates the local configuration.

Chassis ID

Value of chassis type.

Port ID type

Port information:

·       Interface alias.

·       Port component.

·       MAC address.

·       Network address (IPv4).

·       Interface name.

·       Agent circuit ID.

·       Locally assigned—Indicates the local configuration.

Port ID

Value of the port ID type.

System name

System name of the neighboring router.

System description

System description of the neighboring router.

System capabilities supported

Capabilities supported on the neighboring router:

·       Bridge—Switching is supported.

·       Router—Routing is supported.

System capabilities enabled

Capabilities enabled on the neighboring router:

·       Bridge—Switching is enabled.

·       Router—Routing is enabled.

Management address interface type

Interface type identified by the management address.

Port and protocol VLAN supported

Indicates whether or not protocol VLAN is supported on the port.

Port and protocol VLAN enabled

Indicates whether or not protocol VLAN is enabled on the port.

Auto-negotiation supported

Indicates whether or not auto-negotiation is supported on the port.

Auto-negotiation enabled

Indicates whether or not auto-negotiation is enabled on the port.

OperMau

Speed and duplex state of the port.

Power port class

PoE device type:

·       PSE—Power supply device.

·       PD—Powered device.

PSE power supported

The router can operate as a PSE.

PSE power enabled

The router is operating as a PSE.

PSE pairs control ability

The PSE-PD pair control is available.

Power pairs

PoE mode, Signal or Spare.

Port power classification

Port power classification of the PD:

·       Class 0.

·       Class 1.

·       Class 2.

·       Class 3.

·       Class 4.

Link aggregation supported

Indicates whether or not link aggregation is supported.

Link aggregation enabled

Indicates whether or not link aggregation is enabled.

Aggregation port ID

Aggregation group ID, which is 0 when link aggregation is disabled.

 

display lldp statistics

Syntax

display lldp statistics [ global | interface interface-type interface-number ] [ | { begin | exclude | include } regular-expression ]

View

Any view

Default level

1: Monitor level

Parameters

global: Displays the global LLDP statistics.

interface interface-type interface-number: Specifies a port by its type and number.

|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.

begin: Displays the first line that matches the specified regular expression and all lines that follow.

exclude: Displays all lines that do not match the specified regular expression.

include: Displays all lines that match the specified regular expression.

regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.

Description

Use the display lldp statistics command to display the global LLDP statistics or the LLDP statistics of a port.

If no keyword or argument is specified, this command displays the global LLDP statistics and LLDP statistics on interfaces.

Examples

# Display LLDP statistics on GigabitEthernet 3/1/1.

<Sysname> display lldp statistics interface gigabitethernet 3/1/1

LLDP statistics Information of port 157 [GigabitEthernet3/1/1]:

The number of LLDP frames transmitted            : 15

The number of LLDP frames received               : 0

The number of LLDP frames discarded              : 0

The number of LLDP error frames                  : 0

The number of LLDP TLVs discarded                : 0

The number of LLDP TLVs unrecognized             : 0

The number of LLDP neighbor information aged out : 0

The number of CDP frames received                : 0

The number of CDP frames discarded               : 0

The number of CDP error frames                   : 0

display lldp status

Syntax

display lldp status [ interface interface-type interface-number ] [ | { begin | exclude | include } regular-expression ]

View

Any view

Default level

1: Monitor level

Parameters

interface interface-type interface-number: Specifies a port by its type and number.

|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.

begin: Displays the first line that matches the specified regular expression and all lines that follow.

exclude: Displays all lines that do not match the specified regular expression.

include: Displays all lines that match the specified regular expression.

regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.

Description

Use the display lldp status command to display the LLDP status of a port.

If no port is specified, this command displays the LLDP status for all ports.

Examples

# Display the LLDP status of GigabitEthernet 3/1/1.

<Sysname> display lldp status interface gigabitethernet 3/1/1

Port 157 [GigabitEthernet3/1/1]:

Port status of LLDP            : Enable

Admin status                   : Tx_Rx

Trap flag                      : No

Polling interval               : 0s

 

Number of neighbors:             0

Number of MED neighbors        : 0

Number of CDP neighbors        : 0

Number of sent optional TLV    : 22

Number of received unknown TLV : 0

Table 3 Output description

Field

Description

Port status of LLDP

Indicates whether or not LLDP is enabled on the port.

Admin status

LLDP mode of the port:

·       TxRx—The port sends and receives LLDPDUs.

·       Rx_Only—The port only receives LLDPDUs.

·       Tx_Only—The port only sends LLDPDUs.

·       Disable—The port does not send or receive LLDPDUs.

Trap Flag

Indicates whether or not trapping is enabled.

Polling interval

LLDP polling interval, which is 0 when LLDP polling is disabled.

Number of neighbors

Number of LLDP neighbors connecting to the port.

Number of MED neighbors

Number of MED neighbors connecting to the port.

Number of CDP neighbors

Number of CDP neighbors connecting to the port.

Number of sent optional TLV

Number of optional TLVs contained in an LLDPDU sent through the port.

Number of received unknown TLV

Number of unknown TLVs contained in a received LLDPDU.

 

display lldp tlv-config

Syntax

display lldp tlv-config [ interface interface-type interface-number ] [ | { begin | exclude | include } regular-expression ]

View

Any view

Default level

1: Monitor level

Parameters

interface interface-type interface-number: Specifies a port by its type and number.

|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.

begin: Displays the first line that matches the specified regular expression and all lines that follow.

exclude: Displays all lines that do not match the specified regular expression.

include: Displays all lines that match the specified regular expression.

regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.

Description

Use the display lldp tlv-config command to display the TLVs that are sent through a port.

If no port is specified, this command displays all TLVs that are sent through all ports.

Examples

# Display all TLVs that are sent through GigabitEthernet 3/1/1.

<Sysname> display lldp tlv-config interface gigabitethernet 3/1/1

LLDP tlv-config of port 157 [GigabitEthernet3/1/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

 

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

 

LLDP-MED extend TLV :

Capabilities TLV                  YES        YES

Network Policy TLV                YES        YES

Location Identification TLV       NO         NO

Extended Power via MDI TLV        YES        YES

Inventory TLV                     YES        YES

Table 4 Output description

Field

Description

LLDP tlv-config of port

TLVs that are sent through a port

NAME

TLV type

STATUS

Indicates whether or not a specific type of TLV is sent through a port.

DEFAULT

Indicates whether or not a specific type of TLV is sent through a port by default.

Basic optional TLV

Basic TLVs:

·       Port description TLV.

·       System name TLV.

·       System description TLV.

·       System capabilities TLV.

·       Management address TLV.

IEEE 802.1 extended TLV

IEEE 802.1 extended TLVs:

·       Port VLAN ID TLV.

·       Port and protocol VLAN ID TLV.

·       VLAN name TLV.

IEEE 802.3 extended TLV

IEEE 802.3 extended TLVs:

·       MAC-Physic TLV.

·       Power via MDI TLV.

·       Link aggregation TLV.

·       Maximum frame size TLV.

LLDP-MED extend TLV

MED related LLDP TLVs:

·       Capabilities TLV.

·       Network Policy TLV.

·       Extended Power-via-MDI TLV.

·       Location Identification TLV.

·       Inventory TLV, which can be hardware revision TLV, firmware revision TLV, software revision TLV, serial number TLV, manufacturer name TLV, model name TLV, and asset id TLV.

 

lldp admin-status

Syntax

lldp admin-status { disable | rx | tx | txrx }

undo lldp admin-status

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

disable: Specifies the Disable mode. A port in this mode does not send or receive LLDPDUs.

rx: Specifies the Rx mode. A port in this mode only receives LLDPDUs.

tx: Specifies the Tx mode. A port in this mode only sends LLDPDUs.

txrx: Specifies the TxRx mode. A port in this mode sends and receives LLDPDUs.

Description

Use the lldp admin-status command to specify the LLDP operating mode for a port or all ports in a port group.

Use the undo lldp admin-status command to restore the default LLDP operating mode.

By default, the LLDP operating mode is TxRx.

Examples

# Configure the LLDP operating mode as Rx for GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp admin-status rx

lldp check-change-interval

Syntax

lldp check-change-interval interval

undo lldp check-change-interval

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

interval: Sets the LLDP polling interval, ranging from 1 to 30 seconds.

Description

Use the lldp check-change-interval command to enable LLDP polling and set the polling interval.

Use the undo lldp check-change-interval command to restore the default.

By default, LLDP polling is disabled.

Examples

# Enable LLDP polling on GigabitEthernet 4/1/1, setting the polling interval to 30 seconds.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp check-change-interval 30

lldp compliance admin-status cdp

Syntax

lldp compliance admin-status cdp { disable | txrx }

undo lldp compliance admin-status cdp

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

disable: Specifies the disable mode, where CDP-compatible LLDP cannot receive or transmit CDP packets.

txrx: Specifies the TxRx mode, where CDP-compatible LLDP can send and receive CDP packets.

Description

Use the lldp compliance admin-status cdp command to configure the operating mode of CDP-compatible LLDP on a port or port group.

Use the undo lldp compliance admin-status cdp command to restore the default.

By default, CDP-compatible LLDP operates in disable mode.

For your router to work with Cisco IP phones, you must enable CDP-compatible LLDP globally and then configure CDP-compatible LLDP to operate in TxRx mode on the specified ports.

Related commands: lldp compliance cdp.

Examples

# Configure CDP-compatible LLDP to operate in TxRx mode on GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp compliance admin-status cdp txrx

lldp compliance cdp

Syntax

lldp compliance cdp

undo lldp compliance cdp

View

System view

Default level

2: System level

Parameters

None

Description

Use the lldp compliance cdp command to enable global CDP compatibility.

Use the undo lldp compliance cdp command to restore the default.

By default, CDP compatibility is globally disabled.

Because the maximum TTL allowed by CDP is 255 seconds, the TTL configuration must be no more than 255 seconds for CDP-compatible LLDP to operate with Cisco IP phones. The TTL configuration is the product of the TTL multiplier and the LLDPDU transmit interval.

Related commands: lldp hold-multiplier and lldp timer tx-interval.

Examples

# Enable LLDP to be compatible with CDP globally.

<Sysname> system-view

[Sysname] lldp compliance cdp

lldp enable

Syntax

lldp enable

undo lldp enable

View

System view, Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

None

Description

Use the lldp enable command to enable LLDP.

Use the undo lldp enable command to disable LLDP.

By default, LLDP is enabled on ports, but globally disabled.

LLDP takes effect on a port only when it is enabled both globally and on the port.

Examples

# Disable LLDP on GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] undo lldp enable

lldp encapsulation snap

Syntax

lldp encapsulation snap

undo lldp encapsulation

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

None

Description

Use the lldp encapsulation snap command to configure the encapsulation format for LLDPDUs as SNAP on a port or a group of ports.

Use the undo lldp encapsulation command to restore the default encapsulation format for LLDPDUs.

By default, the encapsulation format for LLDPDUs is Ethernet II.

Examples

# Configure the encapsulation format for LLDPDUs as SNAP on GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp encapsulation snap

lldp fast-count

Syntax

lldp fast-count count

undo lldp fast-count

View

System view

Default level

2: System level

Parameters

count: Sets the number of the LLDPDUs sent each time fast LLDPDU transmission is triggered. This argument ranges from 1 to 10.

Description

Use the lldp fast-count command to set the number of the LLDPDUs sent each time fast LLDPDU transmission is triggered.

Use the undo lldp fast-count command to restore the default.

By default, the number is 3.

Examples

# Configure the router to send four LLDPDUs each time fast LLDPDU transmission is triggered.

<Sysname> system-view

[Sysname] lldp fast-count 4

lldp hold-multiplier

Syntax

lldp hold-multiplier value

undo lldp hold-multiplier

View

System view

Default level

2: System level

Parameters

value: Sets the TTL multiplier, ranging from 2 to 10.

Description

Use the lldp hold-multiplier command to set the TTL multiplier.

Use the undo lldp hold-multiplier command to restore the default.

By default, the TTL multiplier is 4.

The TTL configuration of a router is determined by the following expression:

TTL multiplier × LLDPDU transmit interval

The TTL can be up to 65535 seconds. Longer TTLs will be rounded off to 65535 seconds.

Related commands: lldp timer tx-interval.

Examples

# Set the TTL multiplier to 6.

<Sysname> system-view

[Sysname] lldp hold-multiplier 6

lldp management-address-format string

Syntax

lldp management-address-format string

undo lldp management-address-format

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

None

Description

Use the lldp management-address-format string command to configure the encapsulation format of the management address as strings in TLVs.

Use the undo lldp management-address-format command to restore the default.

By default, the management address is encapsulated in the form of numbers in TLVs.

Examples

# Configure GigabitEthernet 4/1/1 to encapsulate the management address in the form of strings in management address TLVs.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp management-address-format string

lldp management-address-tlv

Syntax

lldp management-address-tlv [ ip-address ]

undo lldp management-address-tlv

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

ip-address: Specifies a management address to be advertised in LLDPDUs.

Description

Use the lldp management-address-tlv command to enable management address advertising and set the management address.

Use the undo lldp management-address-tlv command to disable management address advertising in LLDPDUs.

By default, the management address is advertised through LLDPDUs. For a Layer 2 Ethernet port, the management address is the main IP address of the lowest-ID VLAN carried on the port. If none of the carried VLANs is assigned an IP address, no management address will be advertised. For a Layer 3 Ethernet port, the management address is its own IP address. If no IP address is configured for the Layer 3 Ethernet port, no management address will be advertised.

An LLDPDU carries only one management address TLV. If you set the management address repeatedly, the latest one takes effect.

In Layer 2 Ethernet interface view, if you run the lldp management-address-tlv command without specifying the ip-address argument, the advertised management address is the main IP address of the lowest-ID VLAN carried on the interface. If none of the carried VLANs is assigned an IP address, no management address will be advertised.

In Layer 3 Ethernet interface view, if you run the lldp management-address-tlv command without specifying the ip-address argument, the advertised management address is the IP address of the Layer 3 Ethernet port. If no IP address is configured for the port, no management address will be advertised.

Examples

# Set the management address to 192.6.0.1 for GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp management-address-tlv 192.6.0.1

lldp notification remote-change enable

Syntax

lldp notification remote-change enable

undo lldp notification remote-change enable

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

None

Description

Use the lldp notification remote-change enable command to enable LLDP trapping for a port or all ports in a port group.

Use the undo lldp notification remote-change enable command to restore the default.

By default, LLDP trapping is disabled on ports.

Examples

# Enable LLDP trapping for GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp notification remote-change enable

lldp timer notification-interval

Syntax

lldp timer notification-interval interval

undo lldp timer notification-interval

View

System view

Default level

2: System level

Parameters

interval: Sets the interval to send LLDP traps, ranging from 5 to 3600 seconds.

Description

Use the lldp timer notification-interval command to set the interval to send LLDP traps.

Use the undo lldp timer notification-interval command to restore the default.

By default, the interval to send LLDP traps is 5 seconds.

Examples

# Set the interval to send LLDP traps to 8 seconds.

<Sysname> system-view

[Sysname] lldp timer notification-interval 8

lldp timer reinit-delay

Syntax

lldp timer reinit-delay delay

undo lldp timer reinit-delay

View

System view

Default level

2: System level

Parameters

delay: Sets the LLDP re-initialization delay, ranging from 1 to 10 seconds.

Description

Use the lldp timer reinit-delay command to set the LLDP re-initialization delay.

Use the undo lldp timer reinit-delay command to restore the default.

By default, the LLDP re-initialization delay is 2 seconds.

Examples

# Set the LLDP re-initialization delay to 4 seconds.

<Sysname> system-view

[Sysname] lldp timer reinit-delay 4

lldp timer tx-delay

Syntax

lldp timer tx-delay delay

undo lldp timer tx-delay

View

System view

Default level

2: System level

Parameters

delay: Sets the LLDPDU transmit delay, ranging from 1 to 8192 seconds.

Description

Use the lldp timer tx-delay command to set the LLDPDU transmit delay.

Use the undo lldp timer tx-delay command to restore the default.

By default, the LLDPDU transmit delay is 2 seconds.

H3C recommends that you set the LLDPDU transmit delay to be no greater than a quarter of the LLDPDU transmit interval.

If the LLDPDU transmit delay is greater than the LLDPDU transmit interval, the router uses the LLDPDUs transmit delay as the transmit interval.

Related commands: lldp timer tx-interval.

Examples

# Set the LLDPDU transmit delay to 4 seconds.

<Sysname> system-view

[Sysname] lldp timer tx-delay 4

lldp timer tx-interval

Syntax

lldp timer tx-interval interval

undo lldp timer tx-interval

View

System view

Default level

2: System level

Parameters

interval: Sets the LLDPDU transmit interval, ranging from 5 to 32768 seconds.

Description

Use the lldp timer tx-interval command to set the interval to send LLDPDU transmit interval.

Use the undo lldp timer tx-interval command to restore the default.

By default, the LLDPDU transmit interval is 30 seconds.

To enable local router information to be updated on neighboring routers before being aged out, make sure the LLDPDU transmit interval is shorter than the TTL of the local router information.

H3C recommends that you set the LLDPDU transmit interval to be no smaller than four times the LLDPDU transmit delay.

If the LLDPDU transmit interval is smaller than the LLDPDU transmit delay, the router uses the LLDPDUs transmit delay as the transmit interval.

Related commands: lldp timer tx-delay.

Examples

# Set the LLDPDU transmit interval to 20 seconds.

<Sysname> system-view

[Sysname] lldp timer tx-interval 20

lldp tlv-enable

Syntax

In Layer 2 Ethernet interface view or port group view:

lldp tlv-enable { basic-tlv { all | port-description | system-capability | system-description | system-name } | dot1-tlv { all | port-vlan-id | protocol-vlan-id [ vlan-id ] | vlan-name [ vlan-id ] } | dot3-tlv { all | link-aggregation | mac-physic | max-frame-size | power } | 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 | power-over-ethernet } }

undo lldp tlv-enable { basic-tlv { all | port-description | system-capability | system-description | system-name } | dot1-tlv { all | port-vlan-id | protocol-vlan-id | vlan-name } | dot3-tlv { all | link-aggregation | mac-physic | max-frame-size | power } | med-tlv { all | capability | inventory | location-id | network-policy | power-over-ethernet } }

In Layer 3 Ethernet interface view:

lldp tlv-enable { basic-tlv { all | port-description | system-capability | system-description | system-name } | dot3-tlv { all | link-aggregation | mac-physic | max-frame-size | power } | med-tlv { all | capability | inventory | location-id { civic-address device-type country-code { ca-type ca-value }&<1-10> | elin-address tel-number } | power-over-ethernet } }

undo lldp tlv-enable { basic-tlv { all | port-description | system-capability | system-description | system-name } | dot3-tlv { all | link-aggregation | mac-physic | max-frame-size | power } | med-tlv { all | capability | inventory | location-id | power-over-ethernet } }

View

Layer 2 Ethernet interface view, Layer 3 Ethernet interface view, port group view

Default level

2: System level

Parameters

all: Advertises all basic LLDP TLVs, IEEE 802.1 organizationally specific LLDP TLVs, or IEEE 802.3 organizationally specific LLDP TLVs when the all keyword is specified for basic-tlv, dot1-tlv, or dot3-tlv in Layer 2 Ethernet interface view; advertises all basic LLDP TLVs or IEEE 802.3 organizationally specific LLDP TLVs when the all keyword is specified for basic-tlv or dot3-tlv in Layer 3 Ethernet interface view; or advertises all LLDP-MED TLVs except location identification TLVs when the all keyword is specified for med-tlv, regardless of whether in Layer 2 or Layer 3 Ethernet interface view.

basic-tlv: Advertises basic LLDP TLVs.

port-description: Advertises port description TLVs.

system-capability: Advertises system capabilities TLVs.

system-description: Advertises system description TLVs.

system-name: Advertises system name TLVs.

dot1-tlv: Advertises IEEE 802.1 organizationally specific LLDP TLVs.

port-vlan-id: Advertises port VLAN ID TLVs.

protocol-vlan-id: Advertises port and protocol VLAN ID TLVs.

vlan-name: Advertises VLAN name TLVs.

vlan-id: Specifies the VLAN ID in the TLVs (port and protocol VLAN ID TLVs or VLAN name TLVs) to be advertised. It defaults to the least protocol VLAN ID.

dot3-tlv: Advertises IEEE 802.3 organizationally specific LLDP TLVs.

link-aggregation: Advertises link aggregation group TLVs.

mac-physic: Advertises MAC/PHY configuration/status TLVs.

max-frame-size: Advertises maximum frame size TLVs.

power: Advertises power via MDI TLVs.

med-tlv: Advertises MED related LLDP TLVs.

capability: Advertises LLDP-MED capabilities TLVs.

inventory: Advertises hardware revision TLVs, firmware revision TLVs, software revision TLVs, serial number TLVs, manufacturer name TLVs, model name TLVs, and asset ID TLVs.

location-id: Advertises location identification TLVs.

civic-address: Inserts the address information about the intermediate device in location identification TLVs .

device-type: Device type value. Value 0 specifies a DHCP server, value 1 specifies a switch, and value 2 specifies an LLDP-MED endpoint.

country-code: Country code, corresponding to ISO 3166.

{ ca-type ca-value }&<1-10>: Configures address information, where ca-type represents the address information type, ranging from 0 to 255, ca-value represents address information, a string of 1 to 250 characters, and &<1-10> indicates that you can enter up to 10 such parameters.

elin-address: Inserts telephone numbers for emergencies in location identification TLVs.

tel-number: Telephone number for emergencies, a string of 10 to 25 characters.

network-policy: Advertises network policy TLVs.

power-over-ethernet: Advertises extended power-via-MDI TLVs.

Description

Use the lldp tlv-enable command to configure the types of advertisable TLVs for a port or all ports in a port group.

Use the undo lldp tlv-enable command to disable the router from advertising specific types of TLVs.

By default, the router can advertise on a Layer 2 Ethernet port all types of LLDP TLVs, except location identification TLVs, and advertise on a Layer 3 Ethernet port all types of LLDP TLVs, except IEEE 802.1 organizationally specific TLVs, network policy TLVs, and location identification TLVs.

To enable the router to advertise MED related LLDP TLVs, you must first enable it to advertise LLDP-MED capabilities TLVs.

To disable the router from advertising LLDP-MED capabilities TLVs, you must first disable it from advertising other LLDP-MED TLVs.

To disable the router from advertising MAC/PHY configuration/status TLVs, you must first disable it from advertising LLDP-MED capabilities TLVs.

If you enable the router to advertise LLDP-MED capabilities TLVs, you also enable it to advertise MAC/PHY configuration/status TLVs.

To enable the router to advertise multiple types of TLVs, you can execute the lldp tlv-enable command repeatedly without the all keyword specified.

Examples

# Enable the router to advertise link aggregation TLVs of the IEEE 802.3 organizationally specific TLVs on GigabitEthernet 4/1/1.

<Sysname> system-view

[Sysname] interface gigabitethernet 4/1/1

[Sysname-GigabitEthernet4/1/1] lldp tlv-enable dot3-tlv link-aggregation