< Home

Example for Configuring Congestion Management

Networking Requirements

As shown in Figure 1, The Switch is connected to the router through GE 0/0/3. The 802.1p priorities of voice, video, and data services from the Internet are 7, 5, and 2, and these services can reach users through the router and Switch. To reduce the impact of network congestion and ensure bandwidth for high-priority and low-delay services, you need to set the related parameters according to the following table.

Table 1 Congestion management parameters

Service Type

CoS

WRR

Voice

CS7

0

Video

EF

20

Data

AF2

10

Figure 1 Networking diagram for configuring congestion management

Configuration Roadmap

The configuration roadmap is as follows:
  1. Configure the VLAN for each interface so that devices can communicate with each other at the link layer.

  2. Configure interfaces to trust 802.1p priorities of packets.

  3. Configure the scheduling template and apply the scheduling template to the interface.

Procedure

  1. Configure the VLAN for each interface so that devices can communicate with each other at the link layer.

    <HUAWEI> system-view
    [HUAWEI] sysname Switch
    [Switch] vlan batch 10 20 30
    [Switch] interface gigabitethernet 0/0/1
    [Switch-GigabitEthernet0/0/1] port link-type trunk
    [Switch-GigabitEthernet0/0/1] port trunk allow-pass vlan 10 20 30
    [Switch-GigabitEthernet0/0/1] quit
    [Switch] interface gigabitethernet 0/0/2
    [Switch-GigabitEthernet0/0/2] port link-type trunk
    [Switch-GigabitEthernet0/0/2] port trunk allow-pass vlan 10 20 30
    [Switch-GigabitEthernet0/0/2] quit
    [Switch] interface gigabitethernet 0/0/3
    [Switch-GigabitEthernet0/0/3] port link-type trunk
    [Switch-GigabitEthernet0/0/3] port trunk allow-pass vlan 10 20 30
    [Switch-GigabitEthernet0/0/3] quit

  2. Configure the inbound interface of service packets to trust packet priorities.

    For the priority mapping configuration of the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-S, S5731S-H, S5732-H, S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735S-S, S5735-S-I, S6720-EI, S6720S-EI, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S, refer to Configuring Priority Mapping. For the priority mapping configuration of the S2720-EI, S5720I-SI, S5720-LI, S5720S-LI, S5720S-SI, S5720-SI, S5730S-EI, S5730-SI, S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735-S-I, S5735S-S, S6720-LI, S6720S-LI, S6720S-SI, and S6720-SI, refer to Configuring Priority Mapping.

    The configuration in this step is applicable to the S2720-EI, S5720-LI, S5720S-LI, S5720-SI, S5720S-SI, S5720I-SI, S5730-SI, S5730S-EI, S6720-LI, S6720S-LI, S6720-SI, and S6720S-SI.

    # Configure gigabitethernet0/0/3 to trust 802.1p priorities of packets.

    [Switch] interface gigabitethernet 0/0/3
    [Switch-GigabitEthernet0/0/3] trust 8021p
    [Switch-GigabitEthernet0/0/3] quit

  3. Configure congestion management.

    # Create a scheduling template and set queue scheduling parameters.

    [Switch] qos schedule-profile p1
    [Switch-qos-schedule-profile-p1] qos wrr
    [Switch-qos-schedule-profile-p1] qos queue 7 wrr weight 0
    [Switch-qos-schedule-profile-p1] qos queue 5 wrr weight 20
    [Switch-qos-schedule-profile-p1] qos queue 2 wrr weight 10
    [Switch-qos-schedule-profile-p1] quit

    # Apply the scheduling template to GE 0/0/1 and GE 0/0/2 of the Switch.

    [Switch] interface gigabitethernet 0/0/1
    [Switch-GigabitEthernet0/0/1] qos schedule-profile p1
    [Switch-GigabitEthernet0/0/1] quit
    [Switch] interface gigabitethernet 0/0/2
    [Switch-GigabitEthernet0/0/2] qos schedule-profile p1
    [Switch-GigabitEthernet0/0/2] quit

  4. Verify the configuration.

    # View the scheduling template and queue scheduling parameters.

    [Switch] qos schedule-profile p1
    [Switch-qos-schedule-profile-p1] display this
    #
     qos schedule-profile p1
       qos queue 2 wrr weight 10
       qos queue 5 wrr weight 20
       qos queue 7 wrr weight 0 
    #
    return

Configuration Files

  • Switch configuration file

    #
    sysname Switch
    #
    vlan batch 10 20 30
    #
    interface GigabitEthernet0/0/1
     port link-type trunk
     port trunk allow-pass vlan 10 20 30
     qos schedule-profile p1
    #
    interface GigabitEthernet0/0/2
     port link-type trunk
     port trunk allow-pass vlan 10 20 30
     qos schedule-profile p1
    #
    interface GigabitEthernet0/0/3
     port link-type trunk
     port trunk allow-pass vlan 10 20 30
     trust 8021p
    #
     qos schedule-profile p1
       qos queue 2 wrr weight 10
       qos queue 5 wrr weight 20
       qos queue 7 wrr weight 0
    #
    return
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
Next topic >