- Table of Contents
-
- 03-Layer 2 Command Reference
- 00-Preface
- 01-Ethernet Interface Commands
- 02-Loopback and Null Interface Commands
- 03-VLAN Commands
- 04-MAC Address Table Commands
- 05-Ethernet Link Aggregation Commands
- 06-Spanning Tree Commands
- 07-Layer 2 Forwarding Commands
- 08-PPPoE Commands
- 09-FPGA Fast Forwarding Commands
- 10-QinQ Termination Commands
- Related Documents
-
Title | Size | Download |
---|---|---|
05-Ethernet Link Aggregation Commands | 90.90 KB |
Ethernet link aggregation configuration commands
display link-aggregation load-sharing mode
display link-aggregation member-port
display link-aggregation summary
display link-aggregation verbose
link-aggregation load-sharing mode
link-aggregation port-priority
Ethernet link aggregation configuration commands
Support for the commands in this chapter depends on the device model. For more information, see About the H3C Access Controllers Command References.
default
Use default to restore the default settings for an aggregate interface.
Syntax
default
Views
Layer 2 aggregate interface view
Default command level
2: System level
Usage guidelines
|
CAUTION: The default command might interrupt ongoing network services. Make sure you are fully aware of the impacts of this command when you execute it on a live network. |
This command might fail to restore the default settings for some commands for reasons such as command dependencies and system restrictions. Use the display this command in interface view to identify these commands, and then use their undo forms or follow the command reference to restore their default settings. If your restoration attempt still fails, follow the error message instructions to resolve the problem.
Examples
# Restore the default settings for Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> system-view
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1] default
This command will restore the default settings. Continue? [Y/N]:y
description
Use description to set a description for an interface. For example, you can include information such as the purpose of the interface for ease of management.
Use undo description to restore the default setting.
Syntax
description text
undo description
Default
The description of an interface is interface-name Interface. For example, the default description of Bridge-Aggregation 1 is Bridge-Aggregation1 Interface.
Views
Layer 2 aggregate interface view
Default command level
2: System level
Parameters
text: Specifies the interface description, a string of 1 to 80 characters.
Examples
# Set the description to connect to the lab for Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> system-view
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1] description connect to the lab
display interface
Use display interface to display Layer 2 aggregate interface information.
Syntax
display interface [ bridge-aggregation ] [ brief [ down ] ] [ | { begin | exclude | include } regular-expression ]
display interface bridge-aggregation interface-number [ brief ] [ | { begin | exclude | include } regular-expression ]
Views
Any view
Default command level
1: Monitor level
Parameters
bridge-aggregation: Displays information about Layer 2 aggregate interfaces.
interface-number: Specifies an existing Layer 2 aggregate interface by its number.
brief: Displays brief interface information. If you do not specify this keyword, this command displays detailed interface information.
down: Displays information about interfaces in Down state and the causes. If you do not specify this keyword, this command displays information about Layer 2 aggregate interfaces in all states.
|: 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.
Usage guidelines
If bridge-aggregation is not specified, this command displays information about all interfaces.
If bridge-aggregation is specified without any interface number specified, this command displays information about all aggregate interfaces.
If bridge-aggregation interface-number is specified, this command displays information about the specified Layer 2 aggregate interface.
Examples
# Display information about Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> display interface bridge-aggregation 1
Bridge-Aggregation1 current state: DOWN
IP Packet Frame Type: PKTFMT_ETHNT_2, Hardware Address: 3ce5-a6cf-e383
Description: Bridge-Aggregation1 Interface
Unknown-speed mode, unknown-duplex mode
Link speed type is autonegotiation, link duplex type is autonegotiation
PVID: 1
Port link-type: access
Tagged VLAN ID : none
Untagged VLAN ID : 1
Port priority: 0
Last clearing of counters: Never
# Display brief information about Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> display interface bridge-aggregation 1 brief
The brief information of interface(s) under bridge mode:
Link: ADM - administratively down; Stby - standby
Speed or Duplex: (a)/A - auto; H - half; F - full
Type: A - access; T - trunk; H - hybrid
Interface Link Speed Duplex Type PVID Description
BAGG1 DOWN auto A A 1
# Display information about all Layer 2 aggregate interfaces in Down state.
<Sysname> display interface bridge-aggregation brief down
The brief information of interface(s) under bridge mode:
Link: ADM - administratively down; Stby - standby
Interface Link Cause
BAGG1 DOWN Not connected
Table 1 Command output
Field |
Description |
Bridge-Aggregation1 current state |
Layer 2 aggregate interface status: · DOWN (Administratively)—The interface is administratively shut down with the shutdown command. · DOWN—The interface is administratively up but physically down (possibly because no physical link is present or the link is faulty). · UP—The Ethernet interface is both administratively and physically up. |
Unknown-speed mode, unknown-duplex mode |
The interface speed and duplex mode are unknown. |
PVID |
Port VLAN ID. |
Last clearing of counters |
Time when the reset counters interface command was last used to clear the interface statistics. Never indicates the reset counters interface command has never been used on the interface since the device's startup. |
The brief information of interface(s) under bridge mode |
Brief information about Layer 2 interfaces. |
Link: ADM - administratively down; Stby - standby |
Link status: · ADM—The interface has been administratively shut down. To recover its physical layer state, execute the undo shutdown command. · Stby—The interface is operating as a standby interface. |
Speed or Duplex: (a)/A - auto; H - half; F - full |
If the speed of an interface is automatically negotiated, its speed attribute includes the auto negotiation flag, which is the letter a in parentheses. If the duplex mode of an interface is automatically negotiated, its duplex mode attribute includes the auto negotiation flag, which is the letter a in parentheses or a capital A. Letter H indicates the half duplex mode, and letter F indicates the full duplex mode. |
Type: A - access; T - trunk; H - hybrid |
Link type options for Ethernet interfaces. |
Interface |
Abbreviated interface name. |
Link |
Physical link state of the interface. |
Speed |
Interface speed, in bps. |
Cause |
Cause of a Down physical link. |
display lacp system-id
Use display lacp system-id to display the local system ID.
Syntax
display lacp system-id [ | { begin | exclude | include } regular-expression ]
Views
Any view
Default command level
1: Monitor level
Parameters
|: 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.
Usage guidelines
The system ID contains the system LACP priority and the system MAC address.
You can use the lacp system-priority command to change the LACP priority of the local system. The LACP priority value is specified in decimal format in the lacp system-priority command. However, it is displayed in hexadecimal format in the output from the display lacp system-id command.
Examples
# Display the local system ID.
<Sysname> display lacp system-id
Actor System ID: 0x8000, 0000-fc00-6504
Table 2 Command output
Field |
Description |
Actor System ID: 0x8000, 0000-fc00-6504 |
Local system ID, which contains the system LACP priority (0x8000 in this sample output) and the system MAC address (0000-fc00-6504 in this sample output). |
Related commands
lacp system-priority
display link-aggregation load-sharing mode
Use display link-aggregation load-sharing mode to display global or group-specific link-aggregation load sharing criteria.
Syntax
display link-aggregation load-sharing mode [ interface [ bridge-aggregation interface-number ] ] [ | { begin | exclude | include } regular-expression ]
Views
Any view
Default command level
1: Monitor level
Parameters
bridge-aggregation: Displays the load sharing criteria of the aggregation group corresponding to the specified Layer 2 aggregate interface.
interface-number: Specifies an existing Layer 2 aggregate interface by its 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.
Usage guidelines
To display the global link-aggregation load sharing criteria, run the command without the interface keyword.
To display all group-specific load sharing criteria, run the command with the interface keyword, but do not specify a particular interface.
To display the load sharing criteria of a particular aggregation group, perform the command with the aggregate interface specified.
The bridge-aggregation keyword becomes available only after you create Layer 2 aggregate interfaces on the device.
Examples
# Display the global link-aggregation load sharing criteria.
<Sysname> display link-aggregation load-sharing mode
Link-Aggregation Load-Sharing Mode:
Layer 2 traffic: destination-mac address, source-mac address
# Display the link-aggregation load sharing criteria of the aggregation group corresponding to Layer 2 aggregate interface Bridge-Aggregation 2.
<Sysname> display link-aggregation load-sharing mode interface bridge-aggregation 2
Bridge-Aggregation2 Load-Sharing Mode:
Layer 2 traffic: destination-mac address, source-mac address
Table 3 Command output
Field |
Description |
Link-Aggregation Load-Sharing Mode |
Global link-aggregation load sharing criteria. · By default, the link-aggregation load sharing criteria for Layer 2 traffic are displayed. · If you have configured the global link-aggregation load sharing criteria, the configured ones are displayed. |
Bridge-Aggregation2 Load-Sharing Mode |
Link-aggregation load sharing criteria of the aggregation group corresponding to the aggregate interface Bridge-Aggregation 2. · By default, the global link-aggregation load sharing criteria are displayed. · If you have configured link-aggregation load sharing criteria especially for this aggregation group, the configured ones are displayed. |
Layer 2 traffic: destination-mac address, source-mac address |
Default link-aggregation load sharing criteria for Layer 2 traffic. In this sample output, the criteria are the source and destination MAC addresses of packets. |
display link-aggregation member-port
Use display link-aggregation member-port to display detailed link aggregation information for the specified member ports. If no port is specified, this command displays detailed link aggregation information for all member ports.
Syntax
display link-aggregation member-port [ interface-list ] [ | { begin | exclude | include } regular-expression ]
Views
Any view
Default command level
1: Monitor level
Parameters
interface-list: Specifies a list of link aggregation member ports, in the format interface-type interface-number1 [ to interface-type interface-number2 ], where interface-type interface-number specifies an interface 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.
Usage guidelines
Only the port number and operational key of a member port in a static aggregation group are displayed, because the aggregation group is not aware of the partner's information.
Examples
# Display detailed link aggregation information for GigabitEthernet 1/0/1, a member port of a static aggregation group.
<Sysname> display link-aggregation member-port GigabitEthernet 1/0/1
GigabitEthernet1/0/1:
Aggregation Interface: Bridge-Aggregation1
Port Number: 1
Port Priority: 32768
Oper-Key: 1
Table 4 Command output
Field |
Description |
Aggregation Interface |
Aggregate interface to which the member port belongs. |
Port Priority |
Aggregation priority of the port. |
Oper-key |
Operational key. |
display link-aggregation summary
Use display link-aggregation summary to display summary information about all aggregation groups.
Syntax
display link-aggregation summary [ | { begin | exclude | include } regular-expression ]
Views
Any view
Default command level
1: Monitor level
Parameters
|: 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.
Usage guidelines
The information about the remote system for a static link aggregation group might be displayed as none or might not be displayed, because the aggregation group is not aware of the partner's information.
Examples
# Display the summary information for all aggregation groups.
<Sysname> display link-aggregation summary
Aggregation Interface Type:
BAGG -- Bridge-Aggregation, RAGG -- Route-Aggregation
Loadsharing Type: Shar -- Loadsharing, NonS -- Non-Loadsharing
AGG Select Unselect Share
Interface Ports Ports Type
--------------------------------------------------------------------------------
BAGG1 2 0 Shar
Table 5 Command output
Field |
Description |
Aggregation Interface Type |
Aggregate interface type: BAGG (Layer 2 aggregate interface). |
Loadsharing Type |
Load sharing type: · Shar—Load sharing. · NonS—Non-load sharing. |
AGG Interface |
Type and number of the aggregate interface. |
Select Ports |
Total number of Selected ports. |
Unselect Ports |
Total number of Unselected ports. |
Share Type |
Load sharing type. |
display link-aggregation verbose
Use display link-aggregation verbose to display detailed information about the aggregation groups corresponding to the aggregate interfaces.
Syntax
display link-aggregation verbose [ bridge-aggregation [ interface-number ] ] [ | { begin | exclude | include } regular-expression ]
Views
Any view
Default command level
1: Monitor level
Parameters
bridge-aggregation: Displays detailed information about the Layer 2 aggregation groups corresponding to Layer 2 aggregate interfaces.
interface-number: Specifies an existing Layer 2 aggregate interface by its 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.
Usage guidelines
To display information about a specific Layer 2 aggregation group, use the display link-aggregation verbose bridge-aggregation interface-number command.
To display information about all Layer 2 aggregation groups, use the display link-aggregation verbose bridge-aggregation command.
The bridge-aggregation keyword is available only when you create Layer 2 aggregate interfaces on the device.
Examples
# Display detailed information about the aggregation group corresponding to Layer 2 aggregate interface Bridge-Aggregation 2, which is a static aggregation group.
<Sysname> display link-aggregation verbose bridge-aggregation 2
Loadsharing Type: Shar -- Loadsharing, NonS -- Non-Loadsharing
Port Status: S -- Selected, U -- Unselected
Aggregation Interface: Bridge-Aggregation2
Aggregation Mode: Static
Loadsharing Type: Shar
Port Status Priority Oper-Key
--------------------------------------------------------------------------------
GE1/0/2 S 32768 1
GE1/0/3 S 32768 1
Table 6 Command output
Field |
Description |
Loadsharing Type |
Load sharing type: · Shar—Load sharing. · NonS—Non-load sharing. |
Port Status |
Port state: · S—Selected. · U—Unselected. |
Aggregation Interface |
Name of the aggregate interface. |
Port |
Port type and number. |
Status |
Port state: Selected or Unselected. |
Priority |
Port aggregation priority. |
Oper-Key |
Operational key. |
enable snmp trap updown
Use enable snmp trap updown to enable linkUp/linkDown trap generation for the aggregate interface.
Use undo enable snmp trap updown to disable linkUp/linkDown trap generation for the aggregate interface.
Syntax
enable snmp trap updown
undo enable snmp trap updown
Default
LinkUp/linkDown trap generation is enabled for an aggregate interface.
Views
Layer 2 aggregate interface view
Default command level
2: System level
Usage guidelines
For an aggregate interface to generate linkUp/linkDown traps when its link state changes, you must enable linkUp/linkDown trap generation globally with the snmp-agent trap enable [ standard [ linkdown | linkup ] * ] command.
For more information about the snmp-agent trap enable command, see Network Management and Monitoring Command Reference.
Examples
# Enable linkUp/linkDown trap generation on Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> system-view
[Sysname] snmp-agent trap enable
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1] enable snmp trap updown
interface bridge-aggregation
Use interface bridge-aggregation to create a Layer 2 aggregate interface and enter Layer 2 aggregate interface view.
Use undo interface bridge-aggregation to remove a Layer 2 aggregate interface.
Syntax
interface bridge-aggregation interface-number
undo interface bridge-aggregation interface-number
Views
System view
Default command level
2: System level
Parameters
interface-number: Specifies a Layer 2 aggregate interface by its number. The value range varies with devices. For more information, see About the H3C Access Controllers Command References.
Usage guidelines
When you create a Layer 2 aggregate interface, a Layer 2 aggregation group with the same number is automatically created. If you remove the Layer 2 aggregate interface, you also remove the Layer 2 aggregation group, and any member ports will leave the aggregation group.
Examples
# Create Layer 2 aggregate interface Bridge-Aggregation 1 and enter its view.
<Sysname> system-view
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1]
lacp period short
Use lacp period short to set the short LACP timeout interval (1 second) on a port.
Use undo lacp period to restore the default setting.
Syntax
lacp period short
undo lacp period
Default
The LACP timeout interval is the long timeout interval (30 seconds).
Views
Ethernet interface view
Default command level
2: System level
Examples
# Set the short LACP timeout interval (1 second) on GigabitEthernet 1/0/1.
<Sysname> system-view
[Sysname] interface gigabitethernet 1/0/1
[Sysname-GigabitEthernet1/0/1] lacp period short
lacp system-priority
Use lacp system-priority to set the system LACP priority.
Use undo lacp system-priority to restore the default setting.
Syntax
lacp system-priority system-priority
undo lacp system-priority
Default
The system LACP priority is 32768.
Views
System view
Default command level
2: System level
Parameters
system-priority: Specifies the system LACP priority in the range of 0 to 65535. The smaller the value, the higher the system LACP priority.
Examples
# Set the system LACP priority to 64.
<Sysname> system-view
[Sysname] lacp system-priority 64
link-aggregation load-sharing mode
Use link-aggregation load-sharing mode to configure the global or group-specific link-aggregation load sharing criteria.
Use undo link-aggregation load-sharing mode to restore the default setting.
Syntax
link-aggregation load-sharing mode { destination-ip | destination-mac | source-ip | source-mac } *
undo link-aggregation load-sharing mode
Default
The global or group-specific link-aggregation load sharing criteria are source and destination MAC addresses in packets.
Views
System view, Layer 2 aggregate interface view
Default command level
2: System level
Parameters
destination-ip: Performs load sharing in link aggregation groups based on destination IP address.
destination-mac: Performs load sharing in link aggregation groups based on destination MAC address.
source-ip: Performs load sharing in link aggregation groups based on source IP address.
source-mac: Performs load sharing in link aggregation groups based on source MAC address.
Usage guidelines
The load sharing criteria that you configure will overwrite the previous criteria.
Examples
# Configure the source MAC address and destination MAC address as the global link-aggregation load sharing criteria.
<Sysname> system-view
[Sysname] link-aggregation load-sharing mode source-mac destination-mac
# Configure the destination MAC address as the load sharing criterion specific to the link aggregation group of aggregate interface Bridge-Aggregation 1.
<Sysname> system-view
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1] link-aggregation load-sharing mode destination-mac
link-aggregation mode
Use link-aggregation mode dynamic to configure an aggregation group to operate in dynamic aggregation mode.
Use undo link-aggregation mode to restore the default setting.
Syntax
link-aggregation mode dynamic
undo link-aggregation mode
Default
An aggregation group operates in static aggregation mode.
Views
Layer 2 aggregate interface view
Default command level
2: System level
Usage guidelines
To change the aggregation mode of an aggregation group that contains member ports, remove all the member ports from the aggregation group first.
Examples
# Configure the aggregation group that corresponds to Bridge-Aggregation 1 to operate in dynamic aggregation mode.
<Sysname> system-view
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1] link-aggregation mode dynamic
link-aggregation port-priority
Use link-aggregation port-priority to set the aggregation priority of a port.
Use undo link-aggregation port-priority to restore the default setting.
Syntax
link-aggregation port-priority port-priority
undo link-aggregation port-priority
Default
The aggregation priority of a port is 32768.
Views
Ethernet interface view
Default command level
2: System level
Parameters
port-priority: Specifies a port aggregation priority in the range of 0 to 65535. The smaller the value, the higher the port aggregation priority.
Usage guidelines
When the number of ports eligible for becoming Selected ports exceeds the maximum number of Selected ports allowed in an aggregation group, changing the aggregation priority of a port might affect the aggregation state of the ports in the aggregation group.
Examples
# Set the aggregation priority to 64 for port GigabitEthernet 1/0/1.
<Sysname> system-view
[Sysname] interface GigabitEthernet 1/0/1
[Sysname-GigabitEthernet1/0/1] link-aggregation port-priority 64
port link-aggregation group
Use port link-aggregation group to assign an Ethernet interface to an aggregation group.
Use undo port link-aggregation group to remove an Ethernet interface from the aggregation group to which it belongs.
Syntax
port link-aggregation group number
undo port link-aggregation group
Views
Ethernet interface view
Default command level
2: System level
Parameters
number: Specifies the number of an existing aggregate interface corresponding to an aggregation group.
Usage guidelines
A Layer 2 Ethernet interface can be assigned to a Layer 2 aggregation group only.
An Ethernet interface can belong to only one aggregation group.
Examples
# Assign Layer 2 Ethernet interface GigabitEthernet 1/0/1 to Layer 2 aggregation group 1.
<Sysname> system-view
[Sysname] interface GigabitEthernet 1/0/1
[Sysname-GigabitEthernet1/0/1] port link-aggregation group 1
reset counters interface
Use reset counters interface to clear statistics for the specified aggregate interfaces.
Syntax
reset counters interface [ bridge-aggregation [ interface-number ] ]
Views
User view
Default command level
2: System level
Parameters
bridge-aggregation: Clears statistics for Layer 2 aggregate interfaces.
interface-number: Specifies an existing Layer 2 aggregate interface by its number.
Usage guidelines
Before collecting statistics for a Layer 2 aggregate interface within a specific period, clear the existing statistics of the interface.
· If neither bridge-aggregation nor interface-number is specified, the command clears statistics for all interfaces in the system.
· If only the bridge-aggregation keyword is specified, the command clears statistics for all Layer 2 aggregate interfaces.
· If the bridge-aggregation interface-number option is specified, the command clears statistics for the specified Layer 2 aggregate interface.
· The bridge-aggregation keyword becomes available only after you create Layer 2 aggregate interfaces on the device.
Examples
# Clear statistics for Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> reset counters interface bridge-aggregation 1
reset lacp statistics
Use reset lacp statistics to clear LACP statistics for the specified link aggregation member ports.
Syntax
reset lacp statistics [ interface interface-list ]
Views
User view
Default command level
1: Monitor level
Parameters
interface-list: Specifies a list of link aggregation member ports, in the format interface-type interface-number1 [ to interface-type interface-number2 ]. interface-type interface-number specifies an interface by its type and number. If you do not specify any member ports, the command clears LACP statistics for all member ports.
Examples
# Clear LACP statistics for all link aggregation member ports.
<Sysname> reset lacp statistics
Related commands
display link-aggregation member-port
shutdown
Use shutdown to shut down a Layer 2 aggregate interface.
Use undo shutdown to bring up a Layer 2 aggregate interface.
Syntax
shutdown
undo shutdown
Default
Aggregate interfaces are up.
Views
Layer 2 aggregate interface view
Default command level
2: System level
Examples
# Shut down Layer 2 aggregate interface Bridge-Aggregation 1.
<Sysname> system-view
[Sysname] interface bridge-aggregation 1
[Sysname-Bridge-Aggregation1] shutdown