< Home

Configuring Interfaces in a Batch

Context

If you need to perform the same operations on multiple Ethernet interfaces, configuring each interface one by one easily causes incorrect configurations and is labor-intensive.

The port group function easily solves the problem. You can add all the Ethernet interfaces to the same port group. After you run a configuration command once in the port group view, the configuration takes effect on all the Ethernet interfaces in the port group, reducing the configuration workload.

Two types of port groups are available:
  • Temporary port group: To temporarily deliver a configuration to multiple interfaces, you can create a temporary port group. After you deliver the configuration and exit from the port group view, the system automatically deletes the temporary port group.
  • Permanent port group: To deliver configurations to interfaces multiple times, you can create a permanent port group. After you exit from the port group view, the port group and member interfaces in the group still exist, facilitating subsequent batch configuration for the member interfaces. To delete a permanent port group, run the undo port-group { all | port-group-name } command.

Procedure

  • Configure a temporary port group.

    1. Run system-view

      The system view is displayed.

    2. Run port-group group-member { interface-type interface-number1 [ to interface-type interface-number2 ] } &<1-10>

      Or interface range { interface-type interface-number1 [ to interface-type interface-number2 ] } &<1-10>

      A temporary port group is created and the port group view is displayed.

  • Configure a permanent port group.

    1. Run system-view

      The system view is displayed.

    2. Run port-group port-group-name

      A permanent port group is created and the port group view is displayed.

    3. Run group-member { interface-type interface-number1 [ to interface-type interface-number2 ] } &<1-10>

      Ethernet interfaces are added to the permanent port group.

    To configure a temporary or permanent port group for sub-interfaces, replace interface-type interface-number with interface-type interface-number.subinterface-number in the preceding steps to create a temporary or permanent port group for sub-interfaces and enter the port group view.
    • Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S support Ethernet sub-interfaces.

    • Only hybrid and trunk interfaces on the preceding switches support Ethernet sub-interface configuration.
    • After you run the undo portswitch command to switch Layer 2 interfaces on the preceding series of switches into Layer 3 interfaces, you can configure Ethernet sub-interfaces on the interfaces.

    • After an interface is added to an Eth-Trunk, sub-interfaces cannot be configured on the interface.

    • VLAN termination sub-interfaces cannot be created on a VCMP client.

Verifying the Configuration

Run the display port-group [ all | port-group-name ] command to check member interfaces in a permanent port group.

Run the display port-group [ port-group-name ] member-configuration command displays the configuration of each member interface in a specified interface group.

The port group function allows you to configure interfaces in a batch. However, the device does not support query or saving of the port group configuration. You can run the display this command in the interface view of a member interface to check the configuration that takes effect on the interface.

Follow-up Procedure

After a configuration command is executed in the port group view, the device will deliver the configuration to each port in the port group and display the configuration of each port.

You can configure both interface attribute commands and service commands in the port group view. For details about the service commands, see the related documentation.

A command run in the port group view takes effect only on member interfaces that support the command. Therefore, a configuration that is batch delivered may not take effect on all member interfaces. For example, a port group consists of optical and electrical interfaces. If you run the transceiver power low trigger error-down command in the port group view, the configuration will only take effect on the optical interfaces.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >