02-Layer 2-LAN Switching Command Reference

HomeSupportWirelessH3C WX5500E Series Access ControllersReference GuidesCommand ReferencesH3C WX5540E Access Controller Switching Engine Command References(R2607P26)-6W10102-Layer 2-LAN Switching Command Reference
03-Bulk interface configuration commands
Title Size Download
03-Bulk interface configuration commands 73.00 KB

A port group allows only Layer 2 Ethernet interfaces to be added, while an interface range allows multiple types of interfaces, including Ethernet, VLAN, and aggregate interfaces.

Port group configuration commands

display port-group manual

Use display port-group manual to display information about port groups.

Syntax

display port-group manual [ all | name port-group-name ] [ | { begin | exclude | include } regular-expression ]

Views

Any view

Default command level

2: System level

Parameters

all: Displays information about all port groups.

name port-group-name: Specifies the name of a port group, a string of 1 to 32 characters.

|: 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 the all keyword is specified, this command displays the name and member Ethernet interfaces of each port group on the device.

If a port group is specified, this command displays its name and member Ethernet interfaces.

If you do not specify the all keyword or any port group name, the command displays the name of each port group on the device.

Examples

# Display the names of all port groups.

<Sysname> display port-group manual

The following manual port group exist(s):

group1                                    group2

# Display detailed information about all port groups.

<Sysname> display port-group manual all

Member of group1:

    GigabitEthernet1/0/3     GigabitEthernet1/0/4     GigabitEthernet1/0/5

    GigabitEthernet1/0/6     GigabitEthernet1/0/7     GigabitEthernet1/0/8

    GigabitEthernet1/0/9

 

Member of group2:

None

# Display detailed information about the port group named group1.

<Sysname> display port-group manual name group1

Member of group1:

    GigabitEthernet1/0/3     GigabitEthernet1/0/4     GigabitEthernet1/0/5

    GigabitEthernet1/0/6     GigabitEthernet1/0/7     GigabitEthernet1/0/8

    GigabitEthernet1/0/9

group-member

Use group-member to assign Layer 2 Ethernet interfaces to a port group.

Use undo group-member to remove Layer 2 Ethernet interfaces from the port group.

Syntax

group-member interface-list

undo group-member interface-list

Default

A port group does not contain any Layer 2 Ethernet interfaces.

Views

Port group view

Default command level

2: System level

Parameters

interface-list: Specifies an Ethernet interface list in the format of interface-type interface-number [ to interface-type interface-number ] &<1-10>, where &<1-10> indicates that you can specify up to 10 interfaces or interface ranges. Interfaces can include only Layer 2 Ethernet interfaces. If you use the interface-type interface -number to interface-type interface-number option to specify an interface range, make sure that all the interfaces are on the same interface card, and the interface-number argument before to must be less than or equal to that after to.

Examples

# Assign GigabitEthernet 1/0/1 to the port group named group1.

<Sysname> system-view

[Sysname] port-group manual group1

[Sysname-port-group-manual-group1] group-member gigabitethernet 1/0/1

port-group manual

Use port-group manual to create a port group and enter port group view.

Use undo port-group manual to remove a port group.

Syntax

port-group manual port-group-name

undo port-group manual port-group-name

Default

No port groups exist.

Views

System view

Default command level

2: System level

Parameters

port-group-name: Sets the port group name, a string of 1 to 32 characters.

Usage guidelines

In port group view, enter ? at the command prompt to display all commands supported by the port group.

You cannot view or save the configuration of the port group itself in port group view. You can execute the display current-configuration command or the display this command to display current configuration of a member port in its view.

Examples

# Create port group group1.

<Sysname> system-view

[Sysname] port-group manual group1

[Sysname-port-group-manual-group1]

Interface range configuration commands

interface range

Use interface range to create an interface range and enter interface range view.

Syntax

interface range interface-list

Views

System view

Default command level

2: System level

Parameters

interface-list: Specifies an interface list in the format of interface-list = { interface-type interface-number [ to interface-type interface-number ] }&<1-5>, where &<1-5> indicates that you can specify up to five interfaces or interface ranges. Interfaces can include Ethernet, VLAN, and aggregate interfaces. If you use the interface-type interface -number to interface-type interface-number option to specify an interface range, make sure that all the interfaces are on the same interface card, and the interface-number argument before to must be less than or equal to that after to.

Usage guidelines

In interface range view, only the commands supported by the first interface are available. To view the commands supported by the first interface in the interface range, enter the interface range view and enter ? at the command line interface prompt.

To verify the configuration of the first interface in the interface range, execute the display this command in interface range view.

Failure to apply a command on one member interface does not affect the application of the command on the other member interfaces. If applying a command on one member interface fails, the system displays an error message and continues with the next member interface.

Do not assign an aggregate interface and any of its member interfaces to an interface range at the same time. Some commands, after being executed on both an aggregate interface and its member interfaces, can break up the aggregation.

No limit is set on the maximum number of interfaces in an interface range. The more interfaces in an interface range, the longer the command execution time.

Examples

# Shut down interfaces GigabitEthernet 1/0/1 through GigabitEthernet 1/0/24, and VLAN interface 2.

<Sysname> system-view

[Sysname] interface range gigabitethernet 1/0/1 to gigabitethernet 1/0/24 vlan-interface 2

[Sysname-if-range] shutdown

interface range name

Use interface range name name interface interface-list to create an interface range, configure a name for the interface range, add interfaces to the interface range, and enter the interface range view.

Use interface range name without the interface keyword to enter the view of an interface range with the specified name.

Use undo interface range name to delete the interface range with the specified name.

Syntax

interface range name name [ interface interface-list ]

undo interface range name name

Views

System view

Default command level

2: System level

Parameters

name: Interface range name, a case-sensitive string of 1 to 32 characters.

interface-list: Interface list in the format of interface-list = { interface-type interface-number [ to interface-type interface-number ] }&<1-5>. The interface-type interface-number argument specifies an interface by its type and number. &<1-5> indicates that you can specify up to five interfaces or interface lists. Interfaces can include Ethernet, VLAN, and aggregate interfaces. When you specify the to keyword in interface-type interface-number1 to interface-type interface-number2, the interfaces before and after the to keyword must be on the same interface card, and the interface number before to must be no greater than the one after to.

Usage guidelines

You can use this command to assign a name to an interface range and can specify this name rather than the interface range to enter the interface range view.

You can use the display current-configuration | include interface range command to view the member interfaces of an interface range.

Examples

# Add GigabitEthernet 1/0/1 through GigabitEthernet 1/0/12 to interface range named myEthPort, and enter the interface range view.

<Sysname> system-view

[Sysname] interface range name myEthPort interface gigabitethernet 1/0/1 to gigabitethernet 1/0/12

[Sysname-if-range-myEthPort]

# Enter the view of interface range named myEthPort.

<Sysname> system-view

[Sysname] interface range name myEthPort

[Sysname-if-range-myEthPort]

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Intelligent Storage
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
  • Technical Blogs
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网