0% found this document useful (0 votes)
25 views45 pages

ITNET04 Module07 Quality of Service

Module 7 focuses on Quality of Service (QoS) in networking, explaining its purpose, characteristics, and implementation methods. It discusses the importance of prioritizing different types of traffic, such as voice, video, and data, to manage network congestion and ensure quality delivery. The module also outlines various QoS models, including Best-Effort, Integrated Services (IntServ), and Differentiated Services (DiffServ), along with implementation techniques like classification and marking.

Uploaded by

Chaos Victoria
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views45 pages

ITNET04 Module07 Quality of Service

Module 7 focuses on Quality of Service (QoS) in networking, explaining its purpose, characteristics, and implementation methods. It discusses the importance of prioritizing different types of traffic, such as voice, video, and data, to manage network congestion and ensure quality delivery. The module also outlines various QoS models, including Best-Effort, Integrated Services (IntServ), and Differentiated Services (DiffServ), along with implementation techniques like classification and marking.

Uploaded by

Chaos Victoria
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd

Module 7

Quality of Service

ITNET04
WAN Connectivity
Module Objectives

Module Title: Quality of Service


Module Objectives:
• Explain the purpose and characteristics of QoS.
• Explain how networking devices implement QoS
Module References:
 CCNAv7 ENSA– Module 9

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 2
7.1 QoS Overview

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 3
Network Transmission Quality
Different Types of Traffic

In a typical school network, what types of network traffic


would you normally expect to find?

If you were the network administrator, which of these


traffic would you consider important?

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 4
Network Transmission Quality
The Purpose of QoS
 Congestion occurs when multiple
communication lines aggregate onto a
single device, and then much of that
data is placed on fewer outbound
interfaces or onto a slower interface.
 When the volume of traffic is greater
than what can be transported across
the network, devices queue the
? packets in memory until resources
become available to transmit them.
 Queuing packets causes delay
because new packets cannot be
transmitted until previous packets
have been processed.
 Packets will be dropped when memory
fills up.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 5
Network Transmission Quality
The Purpose of QoS • QoS or Quality of Service, allows the
network administrator to prioritize
certain types of traffic over others.

• Example:
• Video traffic and voice traffic require
greater resources, such as
bandwidth, from the network than
other types of traffic.
• Financial transactions are time
sensitive and require minimal
? transmission delay
• An FTP transfer or web traffic
(HTTP) may tolerate some delay in
transmission without significantly
impacting user experience.

• A QoS technique that can help


manage these different traffic is to
classify data into multiple queues
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 6
Network Transmission Quality
Prioritizing Traffic  Packets are buffered at the router and
three priority queues are established:
• High Priority Queue
• Medium Priority Queue
• Low Priority Queue
 Packets from each queue are allocated
resources based on their priority
 QoS is an ever increasing requirement of
networks today due to new applications
which create higher expectations for
quality delivery.
 Note that a device should implement
QoS only when it is experiencing
congestion.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 7
Network Transmission Quality
Bandwidth, Congestion, Delay, and Jitter
 Network bandwidth is measured in the number of bits that can be transmitted in one second
(bps).
 Network congestion causes delay. An interface experiences congestion when it is presented with
more traffic than it can handle.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 8
Network Transmission Quality
Bandwidth, Congestion, Delay, and Jitter
 Delay or latency refers to the time it takes for a packet to travel from the source to the destination.

• Fixed delay – delays that all packets experience regardless of network conditions
Delay Description
Code Delay Time to compress data at source before transmitting to the first internetworking device
Packetization Delay Time to encapsulate a packet with all necessary headers
Serialization Delay Time to transmit a frame onto the network media
De-jitter Delay Time to buffer a flow of packets then send them out in evenly spaced intervals

• Variable delay – delays that are introduced depending on network conditions at a given time
Delay Description
Queuing Delay Time a packet waits to be transmitted on the link
Propagation Delay Time for a packet to travel between source and destination
 Jitter is the variation in delay of received packets.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 9
Network Transmission Quality
Packet Loss
 Without any QoS mechanisms in place,
packets are processed in the order in
which they are received and can be
dropped when congestion occurs.
 Example: A router receives a digital audio
stream for VoIP.
• Because VoIP is time-sensitive, router
must compensate for the jitter that is
encountered.
• Playout delay buffer performs this function
by buffering these packets and then
transmitting them in a steady stream.
• The digital packets are later converted
back to an analog audio stream.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 10
Network Transmission Quality
Packet Loss (Cont.)
 If the jitter is too large that it causes
packets to be received out of the range of
the buffer, the out-of-range packets are
discarded
• For minimal losses, the digital signal
processor (DSP) can interpolate what it
thinks the audio should be and no problem
is audible to the user.
• When jitter exceeds what the DSP can
handle, audio problems are heard.
 In a properly designed network, voice
packet loss should be zero
 Network engineers use QoS mechanisms
to classify voice packets for zero packet
loss.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 11
Traffic Characteristics
Network Traffic Trends  In the year 2000s, the predominant types
of IP traffic are voice, data and video.
• Voice traffic has a predictable bandwidth
need and known packet arrival times.
• Data traffic is not real-time and has an
unpredictable bandwidth need.
• Video traffic is greedy in bandwidth
 According to the Cisco Visual Networking
Index (VNI), video traffic represented 67%
of all traffic in 2014. By 2019, video will
represent 80% of all traffic.
 The type of demands that voice, video,
and data traffic place on the network are
very different.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 12
Traffic Characteristics
Voice
 Characteristics:

• Predictable and smooth.


• Very sensitive to delay and dropped packets;
• Not required to retransmit voice if packets are lost.
• Can tolerate a certain amount of latency, jitter, and
loss without any noticeable effects.
 One-way Requirements:

• Latency <=150 ms.


• Jitter <= 30 ms.
• Voice packet loss <= 1%.
• Bandwidth = 30 to 128 kbps
• Packets must receive a higher priority than other types
of traffic.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 13
Traffic Characteristics
Video
 Characteristics:

• Greedy - has a high volume of data per packet


• Bursty – number and size of video packets sent
varies per unit of time
• Less resilient to loss and drop sensitive, delay
sensitive
• With insufficient bandwidth, video quality typically
degrades (blurry picture or unsynchronized audio)
 One way requirements:

• Latency <= 200 - 400 ms


• Jitter <= 30 – 50ms
• Loss <= 0.1 – 1%
• Bandwidth = 384 Kb/s to 20+ Mb/s
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 14
Traffic Characteristics
Data
 Applications may use TCP or UDP, hence characteristics and requirements vary depending on
application
• Data applications that have no tolerance for data loss, such as email and web pages, use TCP to
ensure packets will be resent in the event they are lost.
• Some TCP applications can be very greedy, consuming a large portion of network capacity (e.g.
FTP)
 Relatively insensitive to drops and delays, but a network administrator still needs to consider the quality
of the user experience.
 Traffic prioritization is determined based on 2 factors:
Is the application interactive?

Yes No

Prioritize for lowest delay among data Delay can vary greatly as long as
Is it Yes
traffic (1-2 sec response time) minimum bandwidth is supplied
mission
critical? Application could benefit from lower delay Provide any leftover bandwidth after all
No
other traffic needs are met
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 15
7.2 QoS Mechanisms

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 16
QoS Models
Selecting an Appropriate QoS Policy Model
 How can QoS be implemented in a network? The three models for implementing QoS are
these:
• Best-effort model
• Integrated services (IntServ)
• Differentiated Services (DiffServ)
 The table in the figure to the left summarizes these three models.

 QoS is implemented in a network using either or both of these:

• IntServ – provides the highest guarantee of QoS, but is resource-intensive


• DiffServ – less resource intensive and more scalable

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 17
QoS Models
Best-Effort
 The basic design of the Internet - treats all network packets the same way and provides no
guarantees
 Basically no QoS - the network cannot tell the difference between packets.

 Pros:

• Most scalable and is limited only by bandwidth


• No special QoS mechanisms needed
• Easiest and quickest model to deploy
 Cons

• No guarantee of delivery – Packets arrive in any order and may not arrive at all
• No preferential treatment of packets hence critical data is handled in the same way as non-essential
data

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 18
QoS Models
Integrated Services (IntServ)
 Provides a way to deliver end-to-end
Qos that real-time applications require
by explicitly managing network
resources to provide QoS to specific
user packet streams.
 Development of the model in 1994 was
motivated by the needs of real-time
applications, such as remote video,
multimedia conferencing, visualization,
and virtual reality
 Uses a connection-oriented approach
inherited from telephony network
design.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 19
QoS Models
Integrated Services (con’t)
 Uses resource reservation and admission-
control to establish and maintain QoS.
• Step 1: The application informs the network of
its traffic profile and requests a particular kind
of service that can encompass its bandwidth
and delay requirements.
• Step 2: IntServ uses the Resource Reservation
Protocol (RSVP) to signal the QoS needs of an
application’s traffic along devices in the end-to-
end path through the network.
• Step 3: If the network devices along the path
can reserve the necessary bandwidth, the
originating application can begin transmitting –
otherwise, no data is sent.
 Provides the highest guarantee of QoS, but is
resource-intensive
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 20
QoS Models
Differentiated Services (DiffServ)
 The differentiated services (DiffServ) QoS
model:
• Specifies a simple and scalable mechanism for
classifying and managing network traffic.
• Provides QoS guarantees on modern IP
networks.
• Can provide low-latency guaranteed service to
critical network traffic such as voice or video.
 Not an end-to-end QoS strategy because it
cannot enforce end-to-end guarantees.
However, it is a more scalable approach to
implementing QoS.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 21
QoS Models
Differentiated Services (Cont.)
 DiffServ divides network traffic into classes
based on business requirements. Each class
can then be assigned a different level of
service.
 DiffServ enforces and applies QoS
mechanisms on a hop-by-hop basis uniformly
applying global meaning to each traffic class
to provide both flexibility and scalability.
 Overcomes the limitations of both the best-
effort and IntServ models by providing an
“almost guaranteed” QoS while still being
cost-effective and scalable.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 22
QoS Implementation Techniques
QoS Tools
 QoS implementation tools can be categorized into three main categories:

• Classification and marking tools – Session traffic is classified into different priority groupings and
packets are marked.
• Congestion avoidance tools – Traffic classes are allotted network resources and some traffic may
be selectively dropped, delayed or remarked to avoid congestion.
• Congestion management tools – During congestion, traffic is queued to await the availability of
those resources; tools include class based weighted fair queuing, and low latency queuing.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 23
QoS Implementation Techniques
Classification and Marking
 Classification and marking allows identification of packet types and determines the class of traffic to
which packets or frames belong so that a QoS policy can be applied
• Layer 2 and 3 - methods include using interfaces, ACLs, and class maps.
• Layers 4 to 7 - using Network Based Application Recognition (NBAR).
 Marking adds a value to the packet header and devices that receive the packet look at this field to
see if it matches a defined policy.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 24
QoS Implementation Techniques
Classification and Marking Technologies
 Marking may be performed at Layer 2 or 3 using various technologies and works by utilizing specific
fields in frame / packet headers

 When deciding whether to mark at Layer 2 or Layer 3, the following points should be considered:

• Layer 2 marking of frames can be performed for non-IP traffic.


• Layer 2 marking of frames is the only QoS option available for switches that are not “IP aware”.
• Layer 3 marking will carry the QoS information end-to-end.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 25
QoS Implementation Techniques
Marking at Layer 2
 802.1Q is the IEEE standard that
supports VLAN tagging at Layer 2
on Ethernet networks.
 IEEE 802.1p is the QoS
prioritization scheme included with
802.1q.
 The standard uses the first three
bits in the Tag Control Information
(TCI) field and identifies the Class
of Service (CoS) markings.
 These three bits allow eight levels
of priority (0-7).

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 26
QoS Implementation Techniques
Marking at Layer 3
 IPv4 and IPv6 specify an 8-bit field in
their headers to carry the packet
marking assigned by the QoS
classification tools.
• IPv4 – Type of Service (ToS) field
• IPv6 – Traffic Class field
 Offers a maximum of 64 possible
classes of service.
 RFC 2474 renames the ToS ad traffic
class fields as the Differentiated services
(DS) field
 Differentiated Service Code Point
(DSCP) is a marking technique that uses
the IP DS field to encode a 6-bit packet
classification code © 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 27
QoS Implementation Techniques
Marking at Layer 3 (Cont.)
The 64 DSCP values are organized into three categories:
 Best-Effort (BE)

• Default for all IP packets. DSCP value is 0 (000000)


• Packets classified into this category are normally handled using best effort delivery
 Expedited Forwarding (EF)

• The DSCP value is 46 (101110)


• Packets classified into this category are those that require low delay, low loss and low jitter.
• Normally should only be used to mark voice packets.
 Assured Forwarding (AF)

• Used to provide priority values and varying levels of reliability to different data applications by
controlling queueing and drop preference
• Allows an operator to provide assurance of delivery as long as the traffic does not exceed some
subscribed rate
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 28
QoS Implementation Techniques
Marking at Layer 3 (Cont.)
 The 64 DSCP values are organized into 3 categories:
Dropping Low Mid High
• Assured Forwarding (AF)
Best Class 4 AF41 AF42 AF43
• The 1st to 3rd bit indicates queueing class - Class 4 is the priority
(34) (36) (38)
best priority queue and Class 1 is the worst queue.
Class 3 AF31 AF32 AF33
• The 4th and 5th bits designate the drop preference.
(26) (28) (30)
• The 6th most significant bit is set to zero.
Class 2 AF21 AF22 AF23
(18) (20) (22)
Class 1 AF11 AF12 AS13
Worst (10) (12) (14)
priority

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 29
QoS Implementation Techniques
 The trust boundary is the starting point at
Trust Boundaries which the network trusts (does not override)
the markings placed by devices on network
traffic
 Best practice is to classify and mark traffic as
close to its source as possible.
 Common devices where the trust boundary is
placed.
• Endpoints with the capability and
intelligence to mark application traffic to
the appropriate Layer 2 CoS or Layer 3
DSCP values. Ex: IP phones, wireless AP,
and videoconferencing systems.
• Access layer switches
• Distribution switches and routers.
 Re-marking of traffic is typically necessary at
the trust boundary.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 30
QoS Implementation Techniques  Packet loss is usually the result of
Avoiding Packet Loss congestion on an interface.
 Most TCP applications experience slowdown
because TCP automatically adjusts to
network congestion.
• Some applications do not use TCP and
cannot handle drops (fragile flows).
 The following approaches can prevent drops
in sensitive applications:
• Increase link capacity to ease or prevent
congestion.
• Prevent congestion by dropping lower-priority
packets before congestion occurs – weighted
random early detection (WRED).
• Guarantee enough bandwidth and increase
buffer space to accommodate bursts of traffic
from fragile flows – queueing algorithms
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 31
QoS Implementation Techniques
Congestion Avoidance
 Congestion avoidance tools monitor
network traffic loads to anticipate and
avoid congestion at common network
bottlenecks before congestion
becomes a problem.
 Congestion avoidance is achieved
through monitoring the average depth
of the queue and dropping packets to
manage queue depth.
 Example:

• As the queue fills up to the maximum


threshold, an increasing percentage of
packets are dropped.
• When the maximum threshold is
passed, all packets are dropped.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 32
QoS Implementation Techniques
Congestion Avoidance (Cont.)
WRED Example
 The Cisco IOS offers weighted random
early detection (WRED) as a possible
congestion avoidance solution for TCP
traffic.
• Allows for preferential treatment of which
packets will get dropped by setting
individual thresholds for different traffic
classes.
• Provides buffer management and allows
TCP traffic to decrease, or throttle back,
before buffers are exhausted.
• Helps avoid tail drops and maximizes Dropping Low Mid High
network use and TCP-application Class 4 AF41 AF42 AF43
performance. Min 50 30 20
 There is no congestion avoidance for Max 100 50 40
UDP traffic – such as voice traffic. Drop % 5% 10% 20%
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 33
QoS Implementation Techniques
Congestion Management
 If QoS is used in a network, the QoS policy implemented by the network administrator becomes
active when congestion occurs on the link.
 Queuing is a congestion management tool that can buffer, prioritize, and if required, reorder
packets before being transmitted to the destination.

 Some common queuing


algorithms:
• First-In, First-Out (FIFO)
• Weighted Fair Queuing
(WFQ)
• Class-Based Weighted
Fair Queuing (CBWFQ)
• Low Latency Queuing
(LLQ)
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 34
Queuing Algorithms
First In First Out (FIFO)
 Involves buffering and forwarding of packets in the order of arrival (a.k.a. first-come, first-served)

 No concept of priority or classes of traffic  Single queue, equal treatment of all packets.

 Important or time-sensitive traffic can be dropped when congestion occurs on the

 Used on serial interfaces at E1 (2.048 Mbps) speed and below by default if no other strategy used.

 Effective for large links that have little delay and minimal congestion

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 35
Queuing Algorithms
Weighted Fair Queuing (WFQ)  Automated scheduling method that
provides fair bandwidth allocation to all
network traffic.
 Traffic is classified into conversations or
flows based on packet header addressing,
including source/destination IP addresses,
MAC addresses, port numbers, protocols,
and type of service (ToS) values.
 Applies priority, or weights per flow of
traffic then determines how much
bandwidth each flow is allowed relative to
other flows.
 Schedules interactive traffic to the front of
a queue to reduce response time. It then
shares the remaining bandwidth among
high-bandwidth flows.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 36
Queuing Algorithms
Class-Based Weighted Fair Queuing (CBWFQ)
 Extends the standard WFQ functionality to provide support for user-defined traffic classes.

 User can define traffic classes based on match criteria including protocols, ACLs, and input
interfaces, then assign characteristics

• To characterize a class,
bandwidth, weight, and
maximum packet limit is
assigned.
• A FIFO queue is reserved for
each class, and traffic belonging
to a class is directed to the
queue.
• The bandwidth assigned to a
class is the guaranteed
bandwidth delivered to the class
during congestion.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 37
Queuing Algorithms
Low Latency Queuing (LLQ)
 Brings strict priority queuing (PQ)
to CBWFQ to reduce jitter for
time-sensitive data
 Strict PQ allows delay-sensitive
data to be sent before packets in
other queues.
 If CBWFQ only, all packets are
serviced fairly based on weight 
can cause issue for voice traffic
that if delay intolerant
 With LLQ, delay-sensitive data is
sent first, giving preferential
treatment before packets in other
queues are treated.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 38
QoS Implementation Techniques
Congestion Management
 Traffic shaping and policing are two mechanisms provided by the Cisco IOS QoS software to
additionally prevent and manage congestion.
 Packets are queued and forwarded out the egress interface based on their defined QoS
shaping and policing policy.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 39
QoS Implementation Techniques
Shaping and Policing
 Traffic shaping retains excess packets in a
queue and then schedules the excess for
later transmission over increments of time.
• The result of traffic shaping is a smoothed
packet output rate as shown in the figure.
• Shaping requires sufficient memory.
• Used on outbound traffic.

 Policing is commonly implemented by


service providers to enforce a contracted
customer information rate (CIR).
• Either drops or remarks excess traffic.
• Often applied to inbound traffic.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 40
Questions?
Module Summary
What Did You Learn In This Module?
• Quality of Service (QoS) is implemented to alleviate the effects of network congestion.
Without QoS:
• Packets are processed in the order in which they are received
• Time-sensitive will be dropped with the same frequency as data that is not time-sensitive
• Queuing packets causes delay
• Fixed delays are: code delay, packetization delay, serialization delay, de-jitter delay.
• Variable delays are: queuing delay, propagation delay
• Jitter is the variation in the delay of received packets.
• Voice traffic is smooth and benign, but it is sensitive to drops and delays. It c an tolerate a
certain amount of latency, jitter, and loss without any noticeable effects.
• Video traffic is bursty, greedy, drop sensitive, and delay sensitive.
• Data traffic often use TCP applications which can retransmit data and, therefore, are not
sensitive to drops and delays.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 42
Module Summary
What Did You Learn In This Module?
• . Models for implementing QoS
• Best effort treats all network packets the same way and provides no guarantees
• IntServ architecture model uses a connection-oriented approach by implementing resource
reservation and admission-control
• DiffServ QoS model divides network traffic into classes based on business requirements.
Each class can then be assigned a different level of service
• Queuing is a congestion management tool that can buffer, prioritize, and, if required,
reorder packets before being transmitted to the destination.
• FIFO queuing buffers and forwards packets in the order of their arrival.
• WFQ provides fair bandwidth allocation by applying priority, or weights, to identified
traffic and classifies it into conversations or flows.
• CBWFQ, is similar to WFQ but uses traffic classes based on match criteria including
protocols, access control lists (ACLs), and input interface
• LLQ feature brings strict priority queuing (PQ) to CBWFQ.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 43
Module Summary
What Did You Learn In This Module?
• Classification determines the class of traffic to which packets or frames belong. Traffic may
be classified using interfaces, ACLs, class maps and Network Based Application
Recognition (NBAR).
• Congestion management includes queuing and scheduling methods where excess traffic is
buffered or queued (and sometimes dropped) while it waits to be sent out an egress
interface.
• Congestion avoidance tools help to monitor network traffic loads to anticipate and avoid
congestion at common network and internetwork bottlenecks before congestion becomes a
problem.

© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 44

You might also like