Modular QoS CLI (MQC)-Marking-Policy Routing

This affiliate has three above sections. The affiliate begins by analytical the fields that can be

marked by the allocation and appearance (C&M) tools. Next, the affiliate covers the mechanics

of the Cisco IOS Modular QoS CLI (MQC), which is acclimated by all the IOS QoS accoutrement that begin

with the words “Class-Based.” Finally, the C&M accoutrement are covered, with best of the content

focused on the best important C&M tool, Class-Based Appearance (CB Marking).

Fields That Can Be Apparent for QoS Purposes

The IP header, LAN trunking headers, Frame Relay header, and ATM corpuscle attack all accept at least

one acreage that can be acclimated to accomplish some anatomy of QoS marking. This area lists and defines

those fields, with the best cogent advantage focused on the IP attack IP Precedence (IPP) and

Differentiated Services Code Point (DSCP) fields.

IP Precedence and DSCP Compared

The IP attack is authentic in RFC 791, including a 1-byte acreage alleged the Blazon of Account (ToS)

byte. The ToS byte was advised to be acclimated as a acreage to mark a packet for analysis with QoS

tools. The ToS byte itself was added subdivided, with the high-order 3 $.25 authentic as the IP

Precedence (IPP) field. The complete account of ethics from the ToS byte’s aboriginal IPP 3-bit field, and

the agnate names, is provided in Table 12-2.

Table 12-2 IP Precedence Ethics and Names

Name Decimal Amount Bifold Value

Routine Precedence 0 000

Priority Precedence 1 001

Immediate Precedence 2 010

Flash Precedence 3 011

Flash Override Precedence 4 100

Critic/Critical Precedence 5 101

Internetwork Control Precedence 6 110

Network Control Precedence 7 111

408 Affiliate 12: Allocation and Marking

Bits 3 through 6 of the ToS byte included banderole fields that were toggled on or off to betoken a

particular QoS service. The final bit (bit 7) was not authentic in RFC 791. The flags were not

used actual often, so in effect, the ToS byte’s capital purpose was to authority the 3-bit IPP field.

A alternation of RFCs collectively alleged Differentiated Services (DiffServ) came forth later. DiffServ

needed added than 3 $.25 to mark packets, so DiffServ connected a redefinition of the ToS byte.

The ToS byte itself was renamed the Differentiated Services (DS) field, and IPP was replaced with

a 6-bit acreage (high-order $.25 0–5) alleged the Differentiated Services Code Point (DSCP) field.

Later, RFC 3168 authentic the low-order 2 $.25 of the DS acreage for use with the QoS Explicit

Congestion Notification (ECN) feature. Figure 12-1 shows the ToS byte’s architecture with the

pre-DiffServ and post-DiffServ analogue of the field.

Figure 12-1 IP ToS Byte and DS Acreage Compared

C&M accoutrement generally mark DSCP or IPP because the IP packet charcoal complete as it is forwarded

throughout an IP network. The added accessible appearance fields abide central Layer 2 headers, which

means the headers are alone back forwarded by a Layer 3 process. Thus, the closing cannot be

used to backpack QoS arrangement above the accepted hop.

DSCP Settings and Terminology

Several DiffServ RFCs advance a set of ethics to use in the DSCP acreage and an adumbrated meaning

for those settings. For instance, RFC 2598 defines a DSCP of decimal 46, with a name Expedited

Forwarding (EF). According to that RFC, packets apparent as EF should be accustomed queuing

preference so that they acquaintance basal latency, but the packets should be policed to prevent

them from demography over a articulation and preventing any added types of cartage from departure an interface

during periods back this acute cartage alcove or exceeds the interface bandwidth. These

suggested settings, and the associated QoS behavior recommended back application anniversary setting, are

called Per-Hop Behaviors (PHBs) by DiffServ. (The accurate archetype listed in this paragraph

is alleged the Expedited Forwarding PHB.)

IP Header,

Before DiffServ

IP Header,

After DiffServ

DS Field*

DSCP ECN

TOS Byte

Precedence TOS CU

Byte 1 Bytes 3-20

Byte 1 Bytes 3-20

8 bits

8 bits

Fields That Can Be Apparent for QoS Purposes 409

Class Selector PHB and DSCP Values

IPP overlaps with the aboriginal 3 $.25 of the DSCP acreage because the DS acreage is artlessly a redefinition

of the aboriginal ToS byte in the IP header. Because of this overlap, RFC 2475 defines a set of

DSCP ethics and PHBs, alleged Chic Selector (CS) PHBs, that accommodate astern compatibility

with IPP. A C&M affection can set a CS DSCP value, and if addition router or about-face aloof looks at

the IPP field, the amount will accomplish faculty from an IPP perspective. Table 12-3 lists the CS DSCP

names and values, and the agnate IPP ethics and names.

Besides defining eight DSCP ethics and their argument names, the CS PHB additionally suggests a simple set

of QoS accomplishments that should be taken based on the CS values. The CS PHB artlessly states that

packets with beyond CS DSCPs should be accustomed bigger queuing alternative than packets with lower

CS DSCPs.

Assured Forwarding PHB and DSCP Values

The Assured Forwarding (AF) PHB (RFC 2597) defines four classes for queuing purposes, along

with three levels of bead anticipation central anniversary queue. To mark packets and analyze into

which of four queues a packet should be placed, forth with one of three bead priorities inside

each queue, the AF PHB defines 12 DSCP ethics and their meanings. The names of the AF

DSCPs accommodate to the afterward format:

AFxy

where x implies one of four queues (values 1 through 4), and y implies one of three bead priorities

(values 1 through 3).

Table 12-3 Default and Chic Selector DSCP Values

DSCP Class

Selector Names

Binary DSCP

Values

IPP Binary

Values IPP Names

Default/CS0* 000000 000 Routine

CS1 001000 001 Priority

CS2 010000 010 Immediate

CS3 011000 011 Flash

CS4 100000 100 Flash Override

CS5 101000 101 Critic/Critical

CS6 110000 110 Internetwork Control

CS7 111000 111 Arrangement Control

*The agreement “CS0” and “Default” both accredit to a bifold DSCP of 000000, but best Cisco IOS commands acquiesce only

the keyword “default” to represent this value.

410 Affiliate 12: Allocation and Marking

The AF PHB suggests that the college the amount of x in the DSCP name AFxy, the bigger the queuing

treatment a packet should get. For example, packets with AF11 DSCPs should get worse queuing

treatment than packets with AF23 DSCP values. Additionally, the AF PHB suggests that the college the

value of y in the DSCP name AFxy, the worse the bead analysis for those packets. (Treating a packet

worse for bead purposes agency that the packet has a college anticipation of actuality dropped.) For example,

packets with AF11 DSCPs should get bigger bead analysis than packets with AF23 DSCP values.

Table 12-4 lists the names of the DSCP values, the queuing classes, and the adumbrated bead likelihood.

The argument AF PHB names do not chase the “bigger-is- better” argumentation in all cases. For example,

the name AF11 represents a decimal amount of 10, and the name AF13 represents a decimal

DSCP of 14. However, AF11 is “better” than AF13, because AF11 and AF13 are in the same

queuing class, but AF11 has a lower anticipation of actuality alone than AF13.

The bifold adaptation of the AF DSCP ethics shows the patterns of the values. The aboriginal 3 $.25 of the

binary DSCP ethics betoken the queuing chic (bits 0 through 2), and the abutting 2 $.25 (bits 3 and 4)

imply the bead preference. As a result, queuing accoutrement that accomplish alone on IPP can still acknowledge to the

AF DSCP values, about authoritative the AF DSCPs astern accordant with non-DiffServ

nodes for queuing purposes.

Expedited Forwarding PHB and DSCP Values

RFC 2598 defines the Expedited Forwarding (EF) PHB, which was declared briefly in the

introduction to this section. This RFC defines a actual simple brace of PHB actions:

■ Chain EF packets so that they get appointed quickly, to accord them low latency.

Table 12-4 Assured Forwarding DSCP Values—Names, Bifold Values, and Decimal Values

Queue

Class Low Bead Anticipation Medium Bead Anticipation High Bead Probability

Name/Decimal/Binary Name/Decimal/Binary Name/Decimal/Binary

1 AF11 / 10 / 001010 AF12 / 12 / 001100 AF13 / 14 / 001110

2 AF21 / 18 / 010010 AF22 / 20 / 010100 AF23 / 22 / 010110

4 AF31 / 26 / 011010 AF32 / 28 / 011100 AF33 / 30 / 011110

5 AF41 / 34 / 100010 AF42 / 36 / 100100 AF43 / 38 / 100110

NOTE To catechumen from the AF name to the decimal equivalent, you can use a simple formula.

If you anticipate of the AF ethics as AFxy, the blueprint is:

8x + 2y = decimal value

For example, AF41 gives you a blueprint of (8 * 4) + (2 * 1) = 34.

Fields That Can Be Apparent for QoS Purposes 411

■ Police the EF packets so that they do not absorb all bandwidth on the articulation or abjure other

queues.

The DSCP amount authentic for EF is alleged EF, with decimal amount 46, bifold amount 101110.

Non-IP Attack Appearance Fields

As IP packets canyon through an internetwork, the packet is encapsulated in a array of other

headers. In several cases, these added headers accept QoS fields that can be acclimated for classification

and marking.

Ethernet LAN Chic of Service

Ethernet supports a 3-bit QoS appearance field, but the acreage alone exists back the Ethernet header

includes either an 802.1Q or ISL trunking header. IEEE 802.1Q defines its QoS acreage as the 3 mostsignificant

bits of the 2-byte Tag Control field, calling the acreage the user-priority bits. ISL defines

the 3 least-significant $.25 from the 1-byte User field, calling this acreage the Chic of Account (CoS).

Generally speaking, best bodies (and best IOS commands) accredit to these fields as CoS, regardless

of the blazon of trunking. Figure 12-2 shows the accepted area of the CoS acreage central ISL and

802.1P headers.

Figure 12-2 LAN CoS Fields

WAN Appearance Fields

Frame Relay and ATM abutment a distinct bit that can be set for QoS purposes, but these distinct bits

are advised for a actual austere use accompanying to bead probability. Frames or beef with these $.25 set to

1 are advised to be bigger candidates to be alone than frames or beef after the bit set to 1.

Named the Frame Relay Discard Eligibility (DE) bit and the ATM Corpuscle Loss Priority (CLP) bit,

these $.25 can be set by a router, or by an ATM or Frame Relay switch. Router and about-face drop

Original Frame

Tag

ISL Header

802.1Q/P

Header

User

Priority VLAN ID

Frame Blazon CoS

Dest. Src

Ether

Type

ISL Attack (26 Bytes

ISL User Acreage (1 byte)

802.1Q Tag Acreage (2 bytes)

412 Affiliate 12: Allocation and Marking

features can again be configured to added aggressively bead frames and beef that accept the DE or

CLP bit set, respectively.

MPLS defines a 3-bit acreage alleged the MPLS Experimental (EXP) bit that is advised for general

QoS marking. Often, C&M accoutrement are acclimated on the bend of MPLS networks to remap DSCP or IPP

values to MPLS Experimental bit ethics to accommodate QoS central the MPLS network.

Locations for Appearance and Matching

Figure 12-3 shows a sample network, with addendum about the locations of the QoS fields.

Figure 12-3 Sample Arrangement Showing Non-IP Markable QoS Fields

In such a network, the IPP and DSCP central the IP packet abide complete from end to end. However,

some accessories may not be able to attending at the IPP or DSCP fields, and some may acquisition it more

convenient to attending at some added attack field. For instance, an MPLS Characterization About-face Router (LSR)

inside the MPLS billow may be configured to accomplish QoS decisions based on the 3-bit MPLS EXP

field in the MPLS label, but clumsy to attending at the encapsulated IP attack and DSCP field. In such

cases, QoS accoutrement may charge to be configured on bend accessories to attending at the DSCP and again mark a

different field.

The non-IP attack markable fields abide in alone genitalia of the network. As a result, those fields can

be acclimated for allocation or appearance alone on the adapted interfaces. The rules for area these

fields (CoS, DE, CLP, EXP) can be acclimated are as follows:

■ For classification—On admission only, and alone if the interface supports that accurate header

field

■ For marking—On departure only, and alone if the interface supports that accurate attack field

SW1 SW2

.1Q

.1Q

S0/0.1

Fa0/0

Hannah

Queue/Drop

Based on Cos

Drop Based on DE Chain Based on EXP

Frame Relay MPLS

R1 R3

R2

Server 1

IP

IP

For example, if CB Appearance were to be configured on R1’s fa0/0.1 802.1Q subinterface, it could

classify admission frames based on their CoS values, and mark approachable frames with a CoS value.

However, on ingress, it could not mark CoS, and on egress, it could not allocate based on CoS.

Similarly, on that aforementioned fa0/0.1 subinterface, CB Appearance could neither allocate nor mark based

on a DE bit, CLP bit, or MPLS EXP bits, because these headers never abide on Ethernet interfaces.

Table 12-5 summarizes the QoS appearance fields.

Marking Acreage Summary

Field Area Length

IP Precedence (IPP) IP attack 3 bits

IP DSCP IP attack 6 bits

DS acreage IP attack 1 byte

ToS byte IP attack 1 byte

CoS ISL and 802.1Q attack 3 bits

Discard Eligible (DE) Frame Relay attack 1 bit

Cell Loss Priority (CLP) ATM corpuscle attack 1 bit

MPLS Experimental MPLS attack 3 bits