Professional Documents
Culture Documents
CoS Overview
Title>
CoS Overview
Circuit-Switched Networks
Historically, telecommunications networks have been based on circuit-switched technologies. In
these networks, a physical path (or dedicated time slot) is allocated to each connection. The
allocation of dedicated resources to each connection means that delays are small and fixed, and
that congestion-related loss cannot occur. To prevent congestion, this type of network blocks new
connection attempts when insufficient resources are available for all potential users.
The inherent CoS associated with a circuit-switched network is very high, because these networks
were designed to support loss-sensitive and delay-sensitive applications, such as voice.
2 www.juniper.net
CoS Overview
Packet-Switched Networks
Packet-switched networks are designed around the concept of statistical multiplexing, which makes
them very efficient for most data communications uses. Rather than blocking new users,
packet-switched networks buffer excess traffic during periods of peak activity, using the principals of
statistical multiplexing. The obvious drawback to this approach is that large buffers equal potentially
large queuing delays. Because no buffer is infinite, the potential for information loss due to
discarded packets during periods of chronic congestion always exists.
While a packet-switched network is extremely efficient and well adapted to most
machine-to-machine applications, the variable delays and potential for loss makes these networks
problematic for real-time and loss-sensitive applications.
www.juniper.net 3
CoS Overview
4 www.juniper.net
CoS Overview
CoS Parameters
Understanding the terms and parameters used to quantify aspects of a network’s CoS is helpful.
Key network CoS parameters include the following:
• Bandwidth: This parameter defines end-to-end information capacity. One approach to
solving network congestion is to increase bandwidth (the theory being that with enough
bandwidth, CoS is not necessary).
• Delay: This parameter defines the typical (or worst case) delay between communicating
endpoints. Delay is caused by the propagation delay associated with transmission lines
and the queuing delays associated with buffering in a statistically multiplexed network.
Reducing queuing delay for certain traffic types is a key goal of CoS.
• Delay Variation: While a long delay is certainly undesirable, having delays that vary over
a wide range is often even more disruptive to a user’s application than a relatively long,
but fixed, delay. Controlling delay variation, also known as jitter, is therefore important
for some applications.
Continued on next page.
www.juniper.net 5
CoS Overview
CoS Parameters (contd.)
• Loss: Information loss can be extremely disruptive to some applications, such as
real-time applications like video or voice, where a retransmission is often more
disruptive than the initial packet loss. For most data communications applications,
packet loss leads to retransmissions and a resulting increase in overall transaction
time. Packet loss can occur due to bit errors or equipment failures, or it can result from
the need to discard when the buffers in a statistically multiplexed network begin to
overflow.
6 www.juniper.net
CoS Overview
www.juniper.net 7
CoS Overview
Integrated Services
The Internet Engineering Task Force (IETF) generated several RFCs around 1994 that described an
integrated-services (IntServ) model for the Internet. IntServ, as the effort became known, was based
on the use of RSVP signaling to reserve resources across network elements for individual flows.
While the intentions were good, concerns about the ability to scale an RSVP signaling plane to
support the global Internet and whether routers could actually maintain the state associated with the
resulting path and reservation state blocks for each microflow, quickly killed any deployment plans
for IntServ.
8 www.juniper.net
CoS Overview
Differentiated Services
With IntServ stalled, the IETF took a different approach and released several RFCs that described a
new model for IP CoS, named Differentiated Services or DiffServ. The differences between DiffServ
and IntServ relate to the fact that DiffServ has no signaling component.
Under the DiffServ model, nodes are expected to recognize and act only on aggregate flows, as
opposed to the individual flows (or microflows) that the IntServ model tracked. An aggregate flow is
referred to as a behavior aggregate (BA) in DiffServ terminology because the node’s behavior is
identical for all traffic associated with a flow aggregate. A key aspect of DiffServ scalability is that a
node must recognize only the class of a particular packet, as opposed to individual application flows.
The slide shows how the DiffServ architecture redefines the original IPv4 ToS field to function as a
6-bit DiffServ field. The DS field carries a DiffServ code point (DSCP) that identifies the BA for each
packet. With 6 bits available, a total of 64 DSCPs are possible.
The last two bits of the DSCP field were originally unused. However, RFC 3168 enables the last two
bits and specifies that they be used for explicit congestion notification.
www.juniper.net 9
CoS Overview
10 www.juniper.net
CoS Overview
www.juniper.net 11
CoS Overview
CoS Domain
A CoS domain is a collection of nodes under a common administrative control with a common set of
PHBs. A domain is made up of edge, or boundary, nodes as well as internal (core) nodes. This
distinction is a critical point because the role of a given device varies based on its designation.
In general terms, edge nodes tend to have more complex data handling and manipulation functions
when compared to a core node. For example, policing, shaping, metering (accounting), and complex
multifield classification functions are normally performed by nodes that are attached to customers
or other domains. In contrast, a core node normally performs only BA-based classification and
transmission scheduling based on defined PHBs.
Because all nodes in a CoS domain are under common control and make use of a common set of
PHBs, expecting that end-to-end performance and service levels can be predicted and met is
reasonable.
12 www.juniper.net
CoS Overview
Per-Hop Behavior
A key component of the DiffServ architecture is the concept of a PHB that describes the externally
visible way in which a DiffServ node handles traffic belonging to a given forwarding class (or BA). The
particular PHB applied to a packet is a function of ingress classification using the DSCP. A DiffServ
node must have a default PHB available for use when handling unclassified traffic. The default PHB
is equivalent to conventional best-effort forwarding.
www.juniper.net 13
CoS Overview
14 www.juniper.net
CoS Overview
Expedited Forwarding
RFC 3246 defines the expedited-forwarding (EF) PHB. This PHB is designed to provide low loss, low
latency, and low jitter services to support delay-sensitive and loss-sensitive applications such as
voice or video conferencing.
Assured Forwarding
RFC 2597 defines the assured-forwarding (AF) PHB. This PHB is primarily concerned with packet loss
because no delay-related parameters are defined. Within the AF category, four classes exist: AF1,
AF2, AF3, and AF4. Within each category, three classes are defined that differ based upon their loss
probability. Put another way, AF11 should have a lower percentage of packet drops when compared
to AF43.
www.juniper.net 15
CoS Overview
16 www.juniper.net
CoS Overview
Recommended DSCPs
The specifications that define the known PHBs include one or more recommended DSCPs that
identify the PHBs. The Internet Assigned Numbers Authority (IANA) maintains a list of recommended
DSCP values at: http://www.iana.org/assignments/dscp-registry. The slide shows these
recommended values along with the associated PHB specification. Note that these values are only
recommendations; the actual DSCP-to-forwarding-class mappings used within a domain are left to
that domain’s administrative authority.
The Junos OS provides support for the recommended DSCP values through the use of code-point
aliases. To view these aliases, use the show class-of-service code-point-aliases
command:
user@R1> show class-of-service code-point-aliases dscp
Code point type: dscp
Alias Bit pattern
af11 001010
af12 001100
af13 001110
af21 010010
af22 010100
af23 010110
af31 011010
af32 011100
. . .
www.juniper.net 17
CoS Overview
IP ToS/DiffServ
As discussed earlier, the IP ToS field is an eight-bit field that includes three precedence bits for traffic
prioritization. In practice, ToS has remained largely unused.
The DSCP also occupies the ToS byte, using the first six bits for traffic prioritization. The DSCP field
supersedes the ToS field, but provides backward compatibility.
18 www.juniper.net
CoS Overview
Traffic Class
IPv6 DiffServ functions much like IPv4 DiffServ, using the traffic class byte in the IPv6 header.
www.juniper.net 19
CoS Overview
IEEE802.1p
The Institute of Electrical and Electronics Engineers (IEEE) defined a CoS signaling technique using
three bits at the beginning of the 802.1p header. These priority bits can be used to differentiate
between service levels at the data link or media access control (MAC) layer.
The 802.1p standard provides eight levels of priority that are defined in ways similar to those of the
IP ToS field.
20 www.juniper.net
CoS Overview
www.juniper.net 21
CoS Overview
22 www.juniper.net
CoS Overview
www.juniper.net 23
CoS Overview
CoS Processing on Junos Devices (contd.)
• Fabric priority: T Series routers incorporate one or more complete Packet Forwarding
Engine (PFE) complexes on each Flexible PIC Concentrator (FPC). Traffic is switched
between PFEs using a nonblocking cross-bar switch fabric instantiated by the system’s
Switch Interface Boards (SIBs). The default behavior sets the switch fabric priority to
match the priority assigned to traffic during ingress classification. This default behavior
minimizes jitter for high-priority traffic by providing consistent traffic handling during
ingress PFE processing, transit across the switch fabric, and during egress PFE
processing. We do not recommend modifying the default switch fabric priority.
• Scheduling and weighted RED: Schedulers are used to service the queues associated
with each forwarding class. Schedulers make use of WRR techniques to service each
queue based on priority level. Congestion avoidance through a weighted RED (WRED)
mechanism is also performed at this stage.
• Rewrite marker: The final CoS stage involves rewriting CoS fields in the packet header
so that the next node can act solely based on exiting CoS values.
24 www.juniper.net
CoS Overview
www.juniper.net 25
CoS Overview
26 www.juniper.net
CoS Overview
www.juniper.net 27
CoS Overview
28 www.juniper.net
CoS Overview
Rewrite Markers
Marker rewrite is a key edge device function. The goal is to mark traffic in a consistent manner at the
network edge to facilitate BA classification in core devices.
The slide shows an example of DSCP-based marking by an edge router. In this case, traffic arriving
from the customer has an all-zeros DS field. The multifield classification actions of the edge router
classify the traffic, and the packet travels through the device. Before the device transmits the packet,
it writes a value into the packet’s CoS field according to the packet’s forwarding class and loss
priority.
The Junos OS supports packet header rewrite actions for several protocols, as shown on the slide.
www.juniper.net 29
CoS Overview
30 www.juniper.net