Using a global IP-Diffserv classifier to mark matching packets with an 802.1p priority

Procedure
  1. Identify a DSCP used to set a policy in packets received from an upstream or edge switch.
  2. Determine the 802.1p priority (0 - 7) you want to apply to packets carrying the identified DSCP. (You can either maintain the priority assigned in the upstream or edge switch, or assign a new priority.)
  3. If necessary, use the qos dscp-map codepoint priority 0 - 7 command to configure the DSCP policy (codepoint and associated 802.1p priority) that you want to use to mark matching packets.
  4. Enable IP-Diffserv mode by entering the qos type-of-service diff-services command.

Syntax:


qos type-of-service diff-services codepoint

Causes the switch to read the codepoint (DSCP) of an incoming IP packet and, when a match occurs, assign the associated 802.1p priority in the DSCP Policy table.

Parameters

no qos type-of-service

Disables all ToS classifier operation.

no qos dscp-map codepoint

Disables direct 802.1p priority assignment to packets carrying the codepoint , by reconfiguring the codepoint priority assignment in the DSCP table to No-override. If this codepoint is in use as a DSCP policy for another Diffserv codepoint, you must disable or redirect the other Diffserv codepoint's DSCP policy before you can disable or change the codepoint. For example, in the first figure shown below, you cannot change the priority for the 000000 codepoint until you redirect the DSCP policy for 000001 from using 000000 as a policy.

show qos type-of-service

Displays the current Type-of-Service configuration. In IP-Diffserv mode, it also shows the current direct 802.1p assignments and the current DSCP assignments covered later in this section.

Examples

show qos type-of-service

An edge switch A in an untagged VLAN assigns a DSCP of 000110 on IP packets it receives on port A6, and handles the packets with high priority (7). When these packets reach interior switch B, you want the switch to handle them with the same high priority. To enable this operation you would configure an 802.1p priority of 7 for packets received with a DSCP of 000110, and then enable diff-services:
Viewing the codepoints available for 802.1p priority assignments
Type-of-Service configuration that enables both 802.1p priority and DSCP policy assignment