As part of studying the 642-642 QoS exam course is seems quite important to understand the relationship between the various ways of marking traffic. Below are some notes I've made so far about these relationships. This is note a post about the inner working of the various PHBs or their use.
DSCP - Differentiated Services Code Point. This is a field that uses 6bits of the TOS field in an IP packet header.
The four assured forwarding classes each include three drop probability classes. In general the higher the first number the better QoS treatment of the packet and the higher the second number the higher the probability the packet will be dropped during a period of congestion. A simple formula to remember the decimal value is AF(8A)+(2B). E.g. AF31 = (83)+(21 )= 26
IP Precedence - This was used prior to the DSCP. It also uses bit from the TOS field found in IP Packet headers although only 3bits rather than the 6bits of DSCP. These three Precedence bits overlap with the most significant bits of the DSCP.
CoS - Class of service. A 3bit field defined under the 802.1p spec and only found in 802.1q tagged Ethernet frames (cisco ISL also supports CoS). Different from Precedence and DSCP as its a layer 2 marking and some networking equipment can only act on layer 2 CoS markings.
A Table showing the relationship between IP Precedence and DSCP:
|Per Hop Behaviour||DSCP||DSCP (binary value)||DSCP (decimal value)||IP Precedence||IP Precedence (binary)|
|Default (no qos)||BE||000000||0||0||000|
|PHB||DSCP (binary value)||CoS|
|Class Selector 1 (CS1)||001000||1|
|Class Selector 2 (CS2)||010000||2|
|Class Selector 3 (CS3)||011000||3|
|Class Selector 4 (CS4)||100000||4|
|Class Selector 5 (CS5)||101000||5|
|Class Selector 6 (CS6)||110000||6|
|Class Selector 7 (CS7)||111000||7|
On Cisco kit these mapping can of course be customised and changed through the cli.