QoS on Subinterface

Table 1. Feature History
Feature Name

Release Information

QoS on Subinterface

This feature enables Quality of Service (QoS) policies to be applied to individual subinterfaces.

A physical interface may be treated as multiple interfaces by configuring one or more logical interfaces called subinterfaces. One use case is separating the traffic of different VLANs by using a separate subinterface for each VLAN.

Quality of Service (QoS) policies may be applied to individual subinterfaces. Configure QoS as usual, specifying the interface and subinterface using the interface:subinterface notation. For example, for GigabitEthernet interface 4, subinterface 100: GigabitEthernet4.100

Limitations

  • Do not configure a QoS policy on both a main interface and one of its subinterfaces. The exception is a class-default shape policy on the main interface.

  • A QoS policy that is applied to a subinterface must have shaping defined. This configured with the shape command. Example:

    policy-map shape_GigabitEthernet4.100
        class class-default
            service-policy xyz_QoS-model
            shape average 100000000

Configuration Example: QoS on Subinterface

This example applies a QoS policy to subinterface GigabitEthernet4.100 (shown in red in the figure below). This subinterface handles traffic for VLAN 100. The QoS policy affects only subinterface GigabitEthernet4.100, and not subinterface GigabitEthernet4.200, which is on the same physical interface.

Configure QoS on Subinterface Using Cisco SD-WAN Manager

To apply a QoS policy to a subinterface using Cisco SD-WAN Manager, the procedure is similar to that used for configuring policies on a main interface. Add a subinterface feature template to the device template for the target device. This enables loading the QoS policy onto the subinterface.

Before you Begin

  • Configure a QoS Policy from Configuration > Policies > Localized Policy > Custom Options > Forwarding Class/QoS.

  • Apply a QoS Policy to a subinterface and define shaping.

    1. From the Cisco SD-WAN Manager menu, choose Configuration > Templates.

    2. Click Feature Templates.


      Note


      In Cisco vManage Release 20.7.x and earlier releases, Feature Templates is called Feature.


    3. Choose an applicable feature template, such as Cisco VPN Interface Ethernet, and go to the ACL/QoS area of the template.

    4. Configure the following fields:

      • Shaping Rate (Kbps)

      • QoS Map

Procedure

This procedure applies a QoS policy to a subinterface.

Prerequisite: One or more class maps have been defined. These assign classes of traffic (for example, VoIP traffic) to specific queues.

Figure 1. Overview of Workflow for Applying a QoS Policy
  1. Create a QoS policy map.

    1. From Cisco SD-WAN Manager, choose Configuration > Policies.

    2. Click Localized Policy.

    3. Click Add Policy to create a new policy map.

    4. Click Next.

    5. Click Add QoS Map and choose Create New from the drop-down menu.

    6. (This step relies on class maps that have been defined. The class maps assign classes of traffic to specific queues. The queues then represent those classes of traffic. This step uses the queues to control how the traffic will be handled.)

      In the Add Queue dialog box, choose queues that represent the types of traffic relevant to the QoS objectives. Configure parameters such as Bandwidth% and Buffer% for the queues. For example, to configure bandwidth for audio traffic, choose a queue that represents audio traffic and configure the bandwidth parameter. Click Save Queue.

    7. Click Save Policy.

  2. Create a QoS policy that uses the QoS policy map defined above.

    See the documentation for creating a QoS policy.

  3. Use a device template to push the QoS policy to the target device.


    Note


    The device policy defines other parts of the device configuration also. This procedure only affects the QoS policy portion.


    1. From Cisco SD-WAN Manager, choose Configuration > Templates.

    2. From the list of templates, locate the device template for the target device.

    3. For the desired template row, click ... and choose Edit.

    4. In the Additional Templates area, in the Policy field, click the drop-down menu and choose the policy name.

    5. Click Update.

    6. Click Next.

    7. In the left pane, choose the target device. The configuration appears in the right pane.

    8. Click Configure Devices to push the policy to the device. Cisco SD-WAN Manager displays the Task View, showing the status of the update tasks.

  4. Load the QoS policy onto the subinterface.

    Prerequisite: The subinterface feature template must already have been added to the device template.

    1. From Cisco SD-WAN Manager, choose Configuration > Templates.

    2. Click Feature Templates.


      Note


      In Cisco vManage Release 20.7.x and earlier releases, Feature Templates is called Feature.


    3. In the list of templates, locate the feature template for the subinterface. This is the subinterface to which you are assigning the QoS policy.

    4. In the Device Templates column, confirm that the feature template is assigned to a device template.

    5. In the Devices Attached column, confirm that the feature template is assigned to a device.

    6. For the desired template row, click ... and choose Edit.

    7. Click ACL/QoS to jump to the ACL/QoS section.

    8. In the Shaping Rate field, use the drop-down menu to choose Global or Device Specific, and enter a shaping rate value.

    9. In the QoS Map field, use the drop-down menu to choose Global and enter the QoS policy map name.

    10. Click Update.

    11. In the left pane, choose the device to view the configuration in the right pane.

    12. Click Configure Devices to push the policy map to the subinterface. Cisco SD-WAN Manager displays the Task View, showing the status of the update tasks.

Configure QoS on a Subinterface Using the CLI

class-map match-any DATA
     match qos-group 1
class-map match-any Queue0
     match qos-group 0
class-map match-any Queue1
     match qos-group 1
class-map match-any Queue2
     match qos-group 2   
class-map match-any Queue7
     match qos-group 7
class-map match-any WEB
     match qos-group 7

policy-map xyz_QoS-model
     class Queue0
          priority percent 37
     class Queue1
          bandwidth percent 33
      class Queue7
            random-detect
           bandwidth percent 10
      class class-default
            random-detect
           bandwidth percent 20
policy-map shape_GigabitEthernet4.100
     class class-default
           service-policy xyz_QoS-model
           shape average 100000000
 !

interface GigabitEthernet4.100
 no shutdown
 encapsulation dot1Q 100
 ip address 173.10.0.2 255.255.255.0
 ip mtu 1496
 service-policy output shape_GigabitEthernet4.100
exit

exit      
interface Tunnel3
 no shutdown
 ip unnumbered GigabitEthernet4.100
 tunnel source GigabitEthernet4.100
 tunnel mode sdwan
exit

sdwan
 interface GigabitEthernet4.100
  tunnel-interface
   encapsulation ipsec
   color private3 restrict
   max-control-connections 0
 
policy
 class-map
  class Queue0 queue 0
  class VOICE queue 0
  class DATA queue 1
  class Queue1 queue 1
  class Queue2 queue 2
  class Queue7 queue 7
  class WEB queue 7
 !