HQoS

This document provides detailed understanding about HQoS and its configuration.

Feature History for HQoS

This table provides release and related information for features explained in this module.

These features are available on all releases subsequent to the one they were introduced in, unless noted otherwise.

Table 1. Feature History for HQoS

Release

Feature

Feature Information

Cisco IOS XE 26.2.1

HQoS: HQoS feature support has been introduced.

Cisco C9610 Series Smart Switches

Cisco IOS XE 26.2.1ea

HQoS: HQoS feature support has been introduced.

Cisco C9550 Series Smart Switches

Cisco IOS XE 17.18.1

HQoS Functionality: Hierarchical Quality of Service (HQoS) is a technology used to guarantee the bandwidth of multiple services of many users in the Differentiated Service (DiffServ) model through a queue scheduling mechanism.

Cisco C9350 Series Smart Switches

Hierarchical Quality of Service

Use Hierarchical Quality of Service (HQoS) to manage traffic by applying a parent policy and a child policy within a two-level hierarchy.


Note


Only two levels of HQoS are supported. A parent policy can contain one child service policy. Additional levels of nested service policies are not supported.


This table lists the operations supported at each level for each policy direction.

Direction

Parent policy

Child policy

Ingress

Policing

Remarking

Egress

Shaping

Queuing

You cannot use HQoS for child-level ingress policing, child-level egress shaping, additional policy nesting, or aggregate policer or shaper configurations.

Parent level

Apply the parent policy as the top-level policy to an interface.

  • For ingress HQoS, the parent policy performs policing.

  • For egress HQoS, the parent policy performs shaping.

Child level

Nest the child policy under the parent policy.

  • For ingress HQoS, the child policy performs remarking.

  • For egress HQoS, the child policy performs queuing.

Prerequisites for HQoS

Before configuring standard Hierarchical Quality of Service (QoS), you must have a thorough understanding of these items:

  • Standard QoS concepts.

  • Classic Cisco IOS QoS.

  • Modular QoS CLI (MQC).

  • Understanding of Virtual Output Queuing (VOQ) architecture.

  • The types of applications used and the traffic patterns on your network.

  • Traffic characteristics and needs of your network. For example, is the traffic on your network bursty? Do you need to reserve bandwidth for voice and video streams?

  • Bandwidth requirements and speed of the network.

  • Location of congestion points in the network.

Restrictions for HQoS

  • You can configure HQoS with a two-level hierarchy: one parent policy and one child policy.

  • In an egress HQoS policy, you can configure shaping in the parent policy and queuing actions in the child policy.

  • For ingress HQoS, you can configure policing in the parent policy and remarking actions in the child policy.

  • Ingress HQoS does not support child-level policing.

  • The parent policy does not support the ratio of remaining bandwidth.

  • HQoS does not support additional nested service policies.

  • HQoS does not allow aggregate policing or shaping configurations.

  • If you configure parent shaping with child priority queuing or policing in an egress HQoS policy, only the HQoS shaper statistics are updated; policing statistics are not updated.

  • You must configure traffic class 7 to use priority level 1.

  • For Cisco C9610 Series Smart Switches, queue limit ranges vary depending on the switch model: Supervisor 3 or Supervisor 3XL.

How to Configure HQoS

Configure HQoS based on the direction of the policy.

  • Configure a parent policing policy and attach a child remarking policy for ingress HQoS.

  • Configure a parent shaping policy and attach a child queuing policy for egress HQoS.

Attach only one child policy to each parent policy.

For information about child policy, refer to How to Configure QoS.

Ingress HQoS configuration example

In ingress HQoS, the parent policy performs policing, and the child policy performs remarking.


Note


The child policy supports remarking only. Child-level policing and queuing are not supported for ingress HQoS.


Configuring the class maps

Device(config)# class-map match-all CS1
Device(config-cmap)# match dscp cs1
Device(config-cmap)# exit
Device(config)# class-map match-all CS2
Device(config-cmap)# match dscp cs2
Device(config-cmap)# exit

Configuring the child remarking policy

Device(config)# policy-map child-policy
Device(config-pmap)# class CS1
Device(config-pmap-c)# set dscp cs2
Device(config-pmap-c)# exit
Device(config-pmap)# class CS2
Device(config-pmap-c)# set dscp cs3
Device(config-pmap-c)# exit
Device(config-pmap)# exit

Configuring the parent policing policy

Device(config)# policy-map parent-policy
Device(config-pmap)# class class-default
Device(config-pmap-c)# police cir 2g
Device(config-pmap-c-police)# service-policy child-policy
Device(config-pmap-c-police)# exit
Device(config-pmap-c)# exit
Device(config-pmap)# exit

Applying the ingress HQoS policy

Device(config)# interface FortyGigabitEthernet6/0/2
Device(config-if)# service-policy input parent-policy
Device(config-if)# end

Verifying ingress HQoS

Device# show policy-map interface FortyGigabitEthernet6/0/2 input

The output displays statistics for the parent policing. It also shows the remarking actions configured in the child policy.

Egress HQoS configuration example

In egress HQoS, the parent policy performs shaping, and the child policy performs queueing.


Note


Egress HQoS supports a parent shaper with a child queuing policy. Other hierarchical action combinations are not supported.


Configuring the child queuing policy

Device(config)# policy-map type queueing child-queueing-policy
Device(config-pmap)# class traffic-class-7
Device(config-pmap-c)# priority level 1
Device(config-pmap-c)# shape average 20g
Device(config-pmap-c)# exit
Device(config-pmap)# class traffic-class-6
Device(config-pmap-c)# shape average percent 1
Device(config-pmap-c)# exit
Device(config-pmap)# class traffic-class-5
Device(config-pmap-c)# shape average 15g
Device(config-pmap-c)# exit
Device(config-pmap)# class class-default
Device(config-pmap-c)# shape average 10g
Device(config-pmap-c)# exit
Device(config-pmap)# exit

Configuring the parent shaping policy

Device(config)# policy-map type queueing parent-shaping-policy
Device(config-pmap)# class class-default
Device(config-pmap-c)# shape average 80g
Device(config-pmap-c)# service-policy child-queueing-policy
Device(config-pmap-c)# exit
Device(config-pmap)# exit

Note


The parent shape rate must be greater than 1.35 Gbps (1.35 gigabits per second).


Applying the egress HQoS policy

Device(config)# interface FiftyGigabitEthernet1/0/30
Device(config-if)# service-policy type queueing output parent-shaping-policy
Device(config-if)# end

Verifying egress HQoS

Use this command to view the egress HQoS configuration and statistics.

Device# show policy-map type queueing interface FiftyGigabitEthernet1/0/30

The output includes the following items:

  • Parent-policy shaping statistics.

  • Child-policy queue statistics.

  • Queue limits and drop counters.

  • Traffic-class shaping rates.

  • Priority levels.