Segment Routing v6 Configuration Guide for Cisco 8000 Series Routers, Cisco IOS XR Releases

PDF

Segment Routing v6 Configuration Guide for Cisco 8000 Series Routers, Cisco IOS XR Releases

SRv6 Layer 3 service gateway enhancements

Want to summarize with AI?

Log in

Explains how service gateways preserve QoS and path visibility by propagating Traffic Class, DSCP, TTL, and ECN information across interconnected SRv6 domains.


The SRv6 l3 gateway traffic class propagation is a SRv6 feature that

  • preserves the SRv6 outer header traffic class value during packet re-origination at the gateway

  • prevents the outgoing SRv6 traffic class value from being overwritten by inner IPv4 or IPv6 packet DSCP values, and

  • maintains consistent quality of service marking across the SRv6 domain.

Starting from Release 26.3.1, these enhancements improve operational consistency for SRv6 Layer 3 service gateway deployments that interconnect distinct SRv6 domains. For more information see Layer 3 service gateway for interconnecting SRv6 domains.

Table 1. Feature History Table

Feature Name

Release Information

Feature Description

SRv6 Layer 3 gateway traffic class propagation

Release 26.3.1

Introduced in this release on: Fixed Systems (8200 [ASIC: Q200, P100], 8700 [ASIC: P100, K100], 8010 [ASIC: A100]); Centralized Systems (8600 [ASIC: Q200]); Modular Systems (8800 [LC ASIC: Q200, P100])

Maintain consistent Quality of Service across your SRv6 domain and prevent high-priority traffic degradation caused by inner IPv4 or IPv6 DSCP values overwriting transport-level markings during packet re-origination.

Key benefits of SRv6 L3 gateway traffic class propagation

  • Preserves SRv6 QoS markings during packet re-origination.

  • Prevents inner IP DSCP values from overwriting SRv6 traffic class values.

  • Maintains consistent QoS behavior across SRv6 domains.

  • Improves traffic-prioritization accuracy.

  • Provides policy-based control of SRv6 encapsulation QoS values.


How SRv6 L3 service gateway works

In SRv6 deployments, QoS markings in the SRv6 outer header are used for traffic prioritization and policy enforcement across the network. During packet re-origination at the SRv6 gateway, retaining the original traffic class marking is vital to maintain consistent QoS. Without proper traffic class propagation and required ingress QoS policies, the gateway may overwrite the SRv6 traffic class value with the inner packet DSCP value, which can lead to incorrect prioritization and inconsistent QoS enforcement.

Summary

The key components involved in the process are:

  • Ingress MQC policy: Matches the required traffic class and explicitly sets the encapsulation class-of-service (CoS) value.

  • SRv6 gateway: Uses the configured CoS value when re-originating the SRv6 packet.

SRv6 L3 gateway traffic class propagation ensures that the correct traffic class marking is preserved or adjusted when packets traverse SRv6 gateways, which is essential for consistent QoS policy enforcement across the network.

Without a QoS policy, incoming SRv6 traffic class and an inner IPv4 or IPv6 DSCP can result in the outgoing SRv6 traffic class being set to CS1. With the QoS policy configured, the outgoing SRv6 traffic class remains as CS3.

Workflow

Incoming Packet                        Outgoing Packet
    +-------------------+                  +-------------------+
    |  SRv6 TC: [Unset] |                  |  SRv6 TC:  CS5(40)|
    +-------------------+  ----------->    +-------------------+
    |  IPv4/v6 DSCP: CS6|                  |  IPv4/v6 DSCP: CS6|
    +-------------------+                  +-------------------+

These stages describe how SRv6 L3 gateway traffic class propagation works.

  1. Ingress: A packet enters the gateway with an encapsulated inner IPv4/IPv6 payload marked with a DSCP value of CS6.

  2. Policy Enforcement: The gateway applies the configured v6aclPolicy. This policy matches the incoming CS6 traffic via the defined access lists and executes the set ip encapsulation class-of-service 40 command to explicitly define the required priority for the SRv6 header.

  3. Egress: The policy ensures that the outer SRv6 Traffic Class field is set to CS5 (40). This remarking action ensures that the SRv6 header accurately reflects the desired QoS priority as the packet exits the gateway, while the inner payload retains its original CS6 marking.


Configure SRv6 L3 gateway traffic class propagation

Configure SRv6 traffic class propagation and ingress QoS policies on the source PE and SRv6 gateway, preserving or intentionally changing the outer Traffic Class value during packet re-origination.

Procedure

  1. Configure traffic-class propagate on the router to allow the router to handle traffic class values during encapsulation.

    Example:

    segment-routing
     srv6
      encapsulation
       traffic-class propagate
    
  2. Create IPv4 and IPv6 access lists to identify the specific traffic flows requiring QoS management.

    ipv4 access-list v4acl
     1 permit ipv4 any any dscp cs6
    !
    ipv6 access-list v6acl
     1 permit ipv6 any any dscp cs6
    
  3. Map the defined access lists to class maps to categorize the identified traffic.

    Example:

    class-map match-any v4aclClass
     match access-group ipv4 v4acl
     end-class-map
    !
    class-map match-any v6aclClass
     match access-group ipv6 v6acl
     end-class-map
    
  4. Create a policy map that matches the class maps and applies the set ip encapsulation class-of-service command to mark the outer SRv6 header.

    Example:

    policy-map v6aclPolicy
     class v4aclClass
      set ip encapsulation class-of-service 40
     !
     class v6aclClass
      set ip encapsulation class-of-service 40
     !
     class class-default
     !
     end-policy-map
    
  5. Attach the policy map to the ingress interfaces to enforce the QoS policy as traffic enters the gateway.

    Example:

    interface Bundle-Ether301.1
     service-policy input v6aclPolicy
    !
    interface Bundle-Ether301.2
     service-policy input v6aclPolicy
    !
    interface Bundle-Ether301.3
     service-policy input v6aclPolicy
    
  6. Verify that the QoS policy is correctly identifying and processing the traffic.

    Example:

    Router# show policy-map interface Bundle-Ether301.1
     
    Bundle-Ether301.1 input: v6aclPolicy
     
     Class v4aclClass
      Classification statistics          (packets/bytes)          (rate - kbps)
        Matched                          : 0/0                    0
        Transmitted                      : 0/0                    0
        Total Dropped                    : 0/0                    0
     
     Class v6aclClass
      Classification statistics          (packets/bytes)          (rate - kbps)
        Matched                          : 701728/68769344        0
        Transmitted                      : 701728/68769344        0
        Total Dropped                    : 0/0                    0
     
     Class class-default
      Classification statistics          (packets/bytes)          (rate - kbps)
        Matched                          : 0/0                    0
        Transmitted                      : 0/0                    0
        Total Dropped                    : 0/0                    0
     
    Policy Bag Stats time: 1776975388166 
    Bundle-Ether301.1 direction output: Service Policy not installed