[All About Switches - Configuration Examples] Example for Configuring HQoS

Latest reply: Aug 23, 2016 19:51:50 5550 2 3 0

Overview of HQoS

Traditional QoS technologies can meet requirements of voice, video, and data services and implement differentiated services. However, these technologies are facing new problems as access users grow in number and the service volume of each user increases continuously. Traditional QoS schedules traffic based on the interface bandwidth and is used on the outbound interface, and traditional QoS is inapplicable to the user side, so it cannot differentiate users. Traditional QoS cannot schedule multiple services of multiple users simultaneously.

To address these issues, HQoS is introduced to differentiate user traffic and schedule traffic based on service priorities. HQoS uses multiple levels of queues to further differentiate service traffic, and provides uniform management and hierarchical scheduling for transmission objects such as users and services.

 

Principles of HQoS

HQoS implements hierarchical scheduling based on queues, as shown in the following figure.

[All About Switches - Configuration Examples] Example for Configuring HQoS-1321127-1

l         Flow queue: HQoS sends packets to flow queues based on mapped internal priorities to differentiate services. Each user has eight flow queues that correspond to eight service priorities (BE, AF1, AF2, AF3, AF4, EF, CS6, and CS7). You can configure Priority Queuing (PQ) or Weighted Fair Queueing (WFQ) for the eight flow queues. Each flow queue supports Weighted Random Early Detection (WRED) and traffic shaping to ensure that high-priority services are scheduled preferentially and obtain higher bandwidth.

  Subscriber queue: Subscriber queues differentiate users. Here, a user refers to a VLAN or VPN. Users are differentiated using access control lists (ACLs). Each user has a subscriber queue that is an aggregation of eight flow queues. Traffic shaping can be configured for a user queue to limit the total bandwidth of each user.

l         Interface queue: The device does not support scheduling based on interface queues, and supports only the mapping from flow queues to interface queues. The mapping allows the device to flexibly send service traffic in a flow queue to an interface queue.

l         Target port: The target port is a physical interface through which data is sent out. After flow queue and subscriber queue scheduling and interface queue scheduling are complete, traffic shaping can be performed for each target port.

The device supports flow queue and subscriber queue scheduling. Packets first enter flow queues, and sent out from subscribe queues after being scheduled. The device supports the mapping between flow queues and interface queues to schedule the same service from different users.

 

Configuration Notes

Product Model

Software Version

S7700&S9700&S12700

S9300&S9300E

S5720HI

V200R006C00 and later versions

l  On modular switches, only X1E series cards support HQoS.

l  The device supports only HQoS in the outbound direction.

l  When each service flow priority of different users is the same, congestion management cannot be performed for them.

 

Networking Requirements

Voice, video, and data services from multiple users are transmitted on an enterprise campus network, and 802.1p priorities of voice, video, and data services are 6, 5, and 2 respectively. Bandwidth needs to be guaranteed for the voice, video, and data services in descending order of priority.

Table 1-1 and Table 1-2 describe the configuration requirement of level-1 scheduling.

Table 1-1 Congestion avoidance parameters of flow queues

Service Type

Color

Lower Drop Threshold (%)

Upper Drop Threshold (%)

Maximum Drop Probability

Voice

Green

80

100

10

Video

Yellow

60

80

20

Data

Red

40

60

40

 

Table 1-2 Congestion management parameters of flow queues

Service Type

CoS Value

Voice

EF

Video

AF3

Data

AF1

 

Because the bandwidth is finite, the device needs to differentiate service priorities and shape traffic from different users to provide different bandwidth. Table 1-3 describes the configuration requirement of level-2 scheduling.

Table 1-3 Traffic shaping parameters of subscriber queues

User

PIR

Users in VLAN 10

8000kbit/s

Users in VLAN 20

5000kbit/s

 

[All About Switches - Configuration Examples] Example for Configuring HQoS-1321127-2

 

Data Plan

The following table describes the VLAN assignment and interface configuration of SwitchA, SwitchB, and SwitchC.

Device

VLAN

Interface

SwitchA

VLAN10

GE1/0/1 and GE1/0/2 are access interfaces and join VLAN 10.

GE2/0/1 is a trunk interface and joins VLAN 10.

SwitchB

VLAN20

GE1/0/1 and GE1/0/2 are access interfaces and join VLAN 20.

GE2/0/1 is a trunk interface and joins VLAN 20.

SwitchC

VLAN10 and VLAN20

GE1/0/1 and GE2/0/1 are trunk interfaces and join VLAN 10 and VLAN 20.

 

Configuration Roadmap

The configuration roadmap is as follows:

1.         Create VLANs and configure interfaces so that the enterprise can access the network through the switch.

2.         Create a DiffServ domain on the switch to map 802.1p priorities of different service packets to PHBs and colors, and bind the DiffServ domain to the inbound interface of the switch.

3.         Configure level-1 scheduling on the switch: Configure a flow queue WRED drop profile, flow queue profile, and profile parameters on the switch so that the switch provides different scheduling priorities, drop profile parameters, and traffic shaping parameters for different services.

4.         Configure ACLs on the switch to differentiate service traffic of different users based on VLAN IDs.

5.         Configure level-2 scheduling on the switch: Configure subscriber queues and traffic shaping parameters on the switch, and reference the flow queue WRED drop profile and flow queue profile to implement HQoS.

 

Procedure

Step 1: Create VLANs and configure interfaces.

# Create VLAN 10 and VLAN 20, configure GE1/0/1, GE1/0/2, and GE2/0/1 as trunk interfaces, and add GE1/0/1 to VLAN 10, GE1/0/2 to VLAN 20, and GE2/0/1 to VLAN 10 and VLAN 20.

<HUAWEI> system-view

[HUAWEI] sysname Switch

[Switch] vlan batch 10 20

[Switch] interface gigabitethernet 1/0/1

[Switch-GigabitEthernet1/0/1] port link-type trunk

[Switch-GigabitEthernet1/0/1] port trunk allow-pass vlan 10

[Switch-GigabitEthernet1/0/1] quit

[Switch] interface gigabitethernet 1/0/2

[Switch-GigabitEthernet1/0/2] port link-type trunk

[Switch-GigabitEthernet1/0/2] port trunk allow-pass vlan 20

[Switch-GigabitEthernet1/0/2] quit

[Switch] interface gigabitethernet 2/0/1

[Switch-GigabitEthernet2/0/1] port link-type trunk

[Switch-GigabitEthernet2/0/1] port trunk allow-pass vlan 10 20

[Switch-GigabitEthernet2/0/1] quit

Step 2: Configure priority mapping.

# Create a DiffServ domain named ds1, map 802.1p priorities 6, 5, 2 to EF, AF3, and AF1, and color packets green, yellow, and red.

[Switch] diffserv domain ds1

[Switch-dsdomain-ds1] 8021p-inbound 6 phb ef green  //Create a DiffServ domain on the switch to map 802.1p priorities of different service packets to PHBs so that packets enter different queues.

[Switch-dsdomain-ds1] 8021p-inbound 5 phb af3 yellow

[Switch-dsdomain-ds1] 8021p-inbound 2 phb af1 red

[Switch-dsdomain-ds1] quit

# Bind the DiffServ domain to inbound interfaces GE1/0/1 and GE1/0/2 of the switch.

[Switch] interface gigabitethernet 1/0/1

[Switch-GigabitEthernet1/0/1] trust upstream ds1  //Apply the DiffServ domain to the interface.

[Switch-GigabitEthernet1/0/1] quit

[Switch] interface gigabitethernet 1/0/2

[Switch-GigabitEthernet1/0/2] trust upstream ds1  //Apply the DiffServ domain to the interface.

[Switch-GigabitEthernet1/0/2] quit

Step 3: Configure level-1 scheduling.

# Create a flow queue WRED drop profile named wred1 on the switch and set parameters of green, yellow, and red packets in the flow queue WRED drop profile.

[Switch] flow-wred-profile wred1  //Create a flow queue WRED drop profile.

[Switch-flow-wred-wred1] color green low-limit 80 high-limit 100 discard-percentage 10  //For green packets, configure the upper and lower drop thresholds to 100% and 80%, and maximum drop probability to 10%.

[Switch-flow-wred-wred1] color yellow low-limit 60 high-limit 80 discard-percentage 20  //For yellow packets, configure the upper and lower drop thresholds to 80% and 60%, and maximum drop probability to 20%.

[Switch-flow-wred-wred1] color red low-limit 40 high-limit 60 discard-percentage 40  //For red packets, configure the upper and lower drop thresholds to 60% and 40%, and maximum drop probability to 40%.

[Switch-flow-wred-wred1] quit

# Configure a flow queue profile named flow1 on the switch, bind flow queue profile flow1 to flow queue WRED drop profile wred1, and configure different scheduling parameters.

[Switch] flow-queue-profile flow1  //Configure a flow queue profile.

[Switch-flow-queue-flow1] qos queue 5 pq flow-wred-profile wred1  //Configure PQ scheduling for queue 5 and reference the flow queue WRED drop profile wred1.

[Switch-flow-queue-flow1] qos queue 5 shaping 4000  //Set the shaping rate to 4000 kbit/s for queue 5.

[Switch-flow-queue-flow1] qos queue 3 wfq weight 20 flow-wred-profile wred1  //Configure WFQ scheduling for queue 3, set the weight to 20, and reference the flow queue WRED drop profile wred1.

[Switch-flow-queue-flow1] qos queue 1 wfq weight 10 flow-wred-profile wred1  //Configure WFQ scheduling for queue 1, set the weight to 10, and reference the flow queue WRED drop profile wred1.

[Switch-flow-queue-flow1] quit

Step 4: Configure ACLs to differentiate users.

# Configure ACL 4001 and ACL 4002 on the switch, and configure ACL rules based on VLAN 10 and VLAN 20.

[Switch] acl number 4001

[Switch-acl-L2-4001] rule 1 permit vlan-id 10   //Configure an ACL to match VLAN 10.

[Switch-acl-L2-4001] quit

[Switch] acl number 4002

[Switch-acl-L2-4002] rule 1 permit vlan-id 20   //Configure an ACL to match VLAN 20.

[Switch-acl-L2-4002] quit

Step 5: Configure level-2 scheduling.

# Configure subscriber queues based on ACL 4001 and ACL 4002 on the switch and reference flow queue profile flow1.

[Switch] interface gigabitethernet 2/0/1

[Switch-GigabitEthernet2/0/1] traffic-user-queue outbound acl 4001 pir 8000 flow-queue-profile flow1  //Configure a subscriber queue based on ACL 4001, set the PIR to 8000 kbit/s, and reference flow queue profile flow1.

[Switch-GigabitEthernet2/0/1] traffic-user-queue outbound acl 4002 pir 5000 flow-queue-profile flow1  //Configure a subscriber queue based on ACL 4002, set the PIR to 5000 kbit/s, and reference flow queue profile flow1.

[Switch-GigabitEthernet2/0/1] quit

[Switch] quit

This article contains more resources

You need to log in to download or view. No account?Register

x
  • x
  • convention:

All_About_Switch
Official Created May 21, 2015 07:34:37 Helpful(1) Helpful(1)

Step 6: Verify the configuration.

# Check the configuration of the WRED drop profile of a flow queue, including the profile name, upper and lower drop thresholds of green, yellow, and red packets, and maximum drop probability.

<Switch> display flow-wred-profile name wred1

Flow-wred-profile[1]: wred1

Queue depth         : 1048576

Color     Low-limit   High-limit  Discard-percentage

-----------------------------------------------------------------

Green     80             100            10

Yellow    60             80             20

Red        40             60             40

-----------------------------------------------------------------

# Check the flow queue profile configuration, including the profile name and WFQ weights.

<Switch> display flow-queue-profile name flow1

Flow-queue-profile[1]: flow1

Queue Schedule(Weight)   Shaping         flow-wred-profile

-----------------------------------------------------------------------

0        PQ                         None               default

1        WFQ(10)               None               wred1

2        PQ                         None              default

3       WFQ(20)                None               wred1

4        PQ                         None              default

5        PQ                        4000(kbps)      wred1

6        PQ                         None              default

7        PQ                         None              default

-----------------------------------------------------------------------

# Simulate voice, video, and data services in VLAN 10 and send traffic at the rate of 10000 kbit/s to GE1/0/1 on the switch. Check traffic statistics on subscriber queues in VLAN 10.

<Switch> display traffic-user-queue statistics interface gigabitethernet 2/0/1 outbound acl 4001

--------------------------------------------------------------------------------

 Interface: GigabitEthernet2/0/1

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         0         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         1         |          packets: pass:                      32,971

                   |                       drop:                     171,196

                   |            bytes:   pass:                  34,421,724

                   |                       drop:                 178,728,624

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         2         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         3         |          packets: pass:                      65,530

                   |                       drop:                     138,636

                   |            bytes:   pass:                  68,413,320

                   |                       drop:                 144,735,984

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         4         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         5         |          packets: pass:                      99,512

                   |                       drop:                     104,654

                   |            bytes:   pass:                 103,890,528

                   |                       drop:                 109,258,776

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         6         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         7         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

The PIR for users in VLAN 10 is 8000 kbit/s and the shaping rate for voice services is 4000 kbit/s, so video and data services share the remaining bandwidth of 4000 kbit/s. According to the preceding information, the ratio of forwarded voice service traffic (number of forwarded packets in queue 5) to forwarded video and data service traffic (number of forwarded packets in queues 3 and 1) approximates 1:1.

# Simulate voice, video, and data services in VLAN 20 and send traffic at the rate of 7000 kbit/s to GE1/0/2 on the switch. Check traffic statistics on subscriber queues in VLAN 20.

<Switch> display traffic-user-queue statistics interface gigabitethernet 2/0/1 outbound acl 4002

--------------------------------------------------------------------------------

 Interface: GigabitEthernet2/0/1

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         0         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         1         |          packets: pass:                       8,916

                   |                       drop:                     136,366

                   |            bytes:   pass:                   9,308,304

                   |                       drop:                 142,366,104

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         2         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         3         |          packets: pass:                      17,420

                   |                       drop:                     127,861

                   |            bytes:   pass:                  18,186,480

                   |                       drop:                 133,486,884

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         4         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         5         |          packets: pass:                     100,374

                   |                       drop:                      44,907

                   |            bytes:   pass:                 104,790,456

                   |                       drop:                  46,882,908

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         6         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

     Queue ID      |                   Statistics information

--------------------------------------------------------------------------------

         7         |          packets: pass:                           0

                   |                       drop:                           0

                   |            bytes:   pass:                           0

                   |                       drop:                           0

--------------------------------------------------------------------------------

The PIR for users in VLAN 20 is 5000 kbit/s and the shaping rate for voice services is 4000 kbit/s, so video and data services share the remaining bandwidth of 1000 kbit/s. According to the preceding information, the ratio of forwarded voice service traffic (number of forwarded packets in queue 5) to forwarded video and data service traffic (number of forwarded packets in queues 3 and 1) approximates 4:1.

 

Configuration Summary

By default, a flow queue maps to an interface queue, that is, flow queues 0 to 7 maps to interface queues 0 to 7 respectively. This example uses the default mapping.

You can change the mapping from flow queues to interface queues so that specified services in a subscriber queue enter interface queues with different priorities for scheduling and other QoS processing according to service requirements.

For example, configure flow mapping profile map1 and map flow queue 1 to interface queue 2.

<HUAWEI> system-view

[HUAWEI] flow-mapping-profile map1

[HUAWEI-flow-mapping-map1] map flow-queue 1 to port-queue 2

 

Configuration File

Configuration file of the switch:

#

sysname Switch

#

vlan batch 10 20

#

diffserv domain ds1

 8021p-inbound 2 phb af1 red

 8021p-inbound 5 phb af3 yellow

 8021p-inbound 6 phb ef green

#

acl number 4001

 rule 1 permit vlan-id 10

acl number 4002

 rule 1 permit vlan-id 20

#

flow-wred-profile wred1

 color green low-limit 80 high-limit 100 discard-percentage 10

 color yellow low-limit 60 high-limit 80 discard-percentage 20

 color red low-limit 40 high-limit 60 discard-percentage 40

#

flow-queue-profile flow1

 qos queue 1 wfq weight 10 flow-wred-profile wred1

 qos queue 3 wfq weight 20 flow-wred-profile wred1

 qos queue 5 flow-wred-profile wred1

#

interface GigabitEthernet1/0/1

 port link-type trunk

 port trunk allow-pass vlan 10

 trust upstream ds1

#

interface GigabitEthernet1/0/2

 port link-type trunk

 port trunk allow-pass vlan 20

 trust upstream ds1

#

interface GigabitEthernet2/0/1

 port link-type trunk

 port trunk allow-pass vlan 10 20

 traffic-user-queue outbound acl 4001 pir 8000 flow-queue-profile flow1

 traffic-user-queue outbound acl 4002 pir 5000 flow-queue-profile flow1

#

return

 



★★★Summary★★★ All About Huawei Switch Features and Configurations

  • x
  • convention:

All_About_Switch
Official Created May 28, 2015 05:58:17 Helpful(1) Helpful(1)

                             

  • x
  • convention:

Comment

Reply
You need to log in to reply to the post Login | Register

Notice Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " Privacy."
If the attachment button is not available, update the Adobe Flash Player to the latest version!
Login and enjoy all the member benefits

Login and enjoy all the member benefits

Login