DSCP classifier policy configuration for input traffic
When a DSCP classifier policy is applied to a subinterface, the policy attempts to match the 6-bit DSCP value in the IP header of incoming packets to one of its entries. If there is a match, the incoming packet is assigned to the specified forwarding class and drop probability; otherwise, the assigned forwarding class is 0 and the assigned drop probability is low.
Packets that require a similar treatment (per-hop behavior) are grouped into an FC, also known as a behavior aggregate. The SR Linux differentiates up to eight forwarding classes.
The drop probability can be one of high, medium, or low. If a queue-template with different WRED slopes is bound to a queue, then packets in that queue with a high drop probability are the first to be dropped when the queue experiences congestion, followed by packets with a medium drop probability, then by packets with a low drop probability. The default is low.
Configuring DSCP classifier policies
The following example creates a DSCP classifier policy:
--{ candidate shared default }--[ ]--
# info qos classifiers
qos {
classifiers {
dscp-policy new-policy {
dscp 0 {
forwarding-class fc0
drop-probability high
}
dscp 8 {
forwarding-class fc1
drop-probability high
}
}
}
}
# copy from state /qos classifiers dscp-policy default to /qos classifiers dscp-policy test
Using a DSCP classifier for VXLAN traffic
On a 7720 IXR-D2/D2L, D3/D3L, D4, and D5 you can use a classifier policy to classify ingress packets received from any remote VXLAN VTEP. The policy applies to payload packets after VXLAN decapsulation is performed.
The following example shows how the DSCP classifier policy created in the previous example (new‑policy) can be used for VXLAN traffic:
--{ candidate shared default }--[ ]--
# info qos classifiers
qos {
classifiers {
vxlan-default new-policy
}
}
DSCP classifier policy application to subinterfaces
If you apply a DSCP classifier policy to input traffic on a subinterface, incoming packets are evaluated against the policy, and matching packets are assigned to the forwarding class and drop probability specified by the policy. If no classifier policy is applied to the subinterface, the system default DSCP classifier (with the reserved name default) is used.
Applying a DSCP classifier policy to input traffic (7250 IXR)
The following example applies a DSCP classifier policy to inbound IPv6 traffic on a subinterface with a 7250 IXR system:
--{ candidate shared default }--[ ]--
# info interface ethernet-1/1
interface ethernet-1/1 {
subinterface 1 {
qos {
input {
classifiers {
ipv6-dscp new-policy
}
}
}
}
}
Applying a DSCP classifier policy to input traffic (7220 IXR)
The following example applies a DSCP classifier policy to inbound traffic on a subinterface with a 7220 IXR-D2/D2L, D3/D3L, D4, and D5 or 7220 IXR-H2, H3, and H4 system:
--{ candidate shared default }--[ ]--
# info interface ethernet-1/1
interface ethernet-1/1 {
subinterface 1 {
qos {
input {
classifiers {
dscp new-policy
}
}
}
}
}