IP Precedence and DSCP Values in QoS

1. Introduction

In Quality of Service (QoS), traffic is classified and prioritized to ensure better performance for critical applications. Two common packet marking mechanisms used in QoS are:

  1. IP Precedence (Legacy – 3 Bits)
  2. Differentiated Services Code Point (DSCP – 6 Bits)

These values are set in the Type of Service (ToS) byte in the IP header to indicate priority levels.


2. IP Precedence (Legacy)

IP PrecedenceBinaryPriority LevelTraffic Type
7111HighestNetwork Control
6110HighInternetwork Control
5101CriticalVoIP, Video
4100HighStreaming Media
3011MediumTransactional Traffic
2010NormalBulk Data
1001LowScavenger Traffic
0000DefaultBest Effort

šŸ“Œ Example Configuration (Mark Traffic with IP Precedence 5 – VoIP):

class-map VOICE
match ip precedence 5

policy-map QOS-POLICY
class VOICE
priority 1000

3. Differentiated Services Code Point (DSCP)

DSCP Classes

DSCP values are divided into different categories:

1ļøāƒ£ Expedited Forwarding (EF – High Priority)

DSCPBinaryDescription
EF (46)101110VoIP, real-time apps

🟢 EF (Expedited Forwarding) is used for low-latency traffic like VoIP.


2ļøāƒ£ Assured Forwarding (AF – Prioritized Traffic)

Assured Forwarding (AF) provides four service classes (AF1-4) with three levels of drop probability (Low, Medium, High).

AF ClassDSCP ValueBinaryDrop Probability
AF1110001010Low
AF1212001100Medium
AF1314001110High
AF2118010010Low
AF2220010100Medium
AF2322010110High
AF3126011010Low
AF3228011100Medium
AF3330011110High
AF4134100010Low
AF4236100100Medium
AF4338100110High

šŸ”µ Example Use Case:


3ļøāƒ£ Default & Best Effort (Low Priority)

DSCPBinaryDescription
CS0 (0)000000Best Effort (Default)
CS1 (8)001000Background Traffic

🚫 CS0 (Best Effort) is used for general internet traffic without priority.


4. Mapping Between IP Precedence and DSCP

IP PrecedenceEquivalent DSCP
0CS0 (0)
1CS1 (8)
2CS2 (16)
3CS3 (24)
4CS4 (32)
5CS5 (40)
6CS6 (48)
7CS7 (56)

5. Configuring DSCP on Cisco Devices

Marking Packets with DSCP

class-map MATCH-VOICE
match ip dscp 46

policy-map QOS-POLICY
class MATCH-VOICE
priority 1000

Trust DSCP on an Interface

conf t
interface GigabitEthernet1/0/1
mls qos trust dscp
exit

6. Summary

renjithbs Avatar

Posted by

Leave a comment