QoSPolicy-map Class Config

set dscp [value]

Sets the Differentiated Services Code Point (DSCP) value in the IP header for packets matching a class map in a policy map, used to mark traffic for QoS classification.

Syntax·Policy-map Class Config
set dscp [value]

When to Use This Command

  • Mark VoIP traffic with DSCP EF (46) to ensure low-latency queuing.
  • Set DSCP AF41 (34) for business-critical data to guarantee bandwidth.
  • Re-mark DSCP from default (0) to CS3 (24) for internal management traffic.
  • Apply DSCP marking to traffic from a specific subnet to differentiate service levels.

Command Examples

Mark VoIP traffic with DSCP EF

set dscp ef
Router(config-pmap-c)# set dscp ef
Router(config-pmap-c)#

The command sets DSCP to EF (46) for all packets matching the class. No output is shown; the prompt confirms the command is accepted.

Set DSCP AF41 for business-critical data

set dscp af41
Router(config-pmap-c)# set dscp af41
Router(config-pmap-c)#

Sets DSCP to AF41 (34) for assured forwarding class 4, low drop probability. No output is displayed.

Understanding the Output

The 'set dscp' command does not produce any output on the CLI; it simply configures the marking action within a policy-map class. To verify the configuration, use 'show policy-map [policy-name]' or 'show running-config | section policy-map'. In the policy-map output, you will see the class and its associated set dscp action. For example: 'class VOICE set dscp ef'. The DSCP value can be specified by name (e.g., ef, af41, cs3) or by number (0-63). A correct configuration shows the DSCP value under the class; a missing or incorrect set command means no marking occurs. In production, verify with 'show policy-map interface' to see actual packet counts and marking statistics.

CCNA Exam Tips

1.

CCNA 200-301 expects you to know DSCP values: EF=46, AF41=34, CS3=24, default=0.

2.

Remember that 'set dscp' is configured in policy-map class config mode, not globally.

3.

The exam may ask which DSCP value to use for VoIP: always EF (46).

4.

Be able to distinguish between 'set dscp' and 'set precedence'—DSCP is more granular.

Common Mistakes

Using 'set dscp' in global config mode instead of policy-map class config mode.

Typing an invalid DSCP name (e.g., 'ef1' instead of 'ef') or number outside 0-63.

Forgetting to apply the policy-map to an interface with 'service-policy' command.

Related Commands

Practice for the CCNA 200-301

Test your knowledge with hundreds of CCNA practice questions covering all exam domains.

Practice CCNA Questions