You are on page 1of 50

CONMUTACIÓN Y RUTEO II

Clase 8
Calidad de Servicio en Redes
IP
Alberto Arellano A. Ing. Msc.
aarellano@espoch.edu.ec
CCNA – CCNP - CCSP
QoS Definition
Before Converged Networks

Traditional data traffic characteristics:


– Bursty data flow
– First-come, first-served access
– Mostly not time-sensitive – delays OK
– Brief outages are survivable
After Converged Networks

Converged traffic characteristics:


– Constant small-packet voice flow
competes with bursty data flow
– Critical traffic must get priority
– Voice and video are time-sensitive
– Brief outages not acceptable
QoS Traffic Requirements: Data

• Different applications have different


traffic characteristics.
• Different versions of the same
application can have different traffic
characteristics.
• Classify data into relative-priority
model with no more than four to five
classes:
Quality of Service
requirements for data

Some traffic can usually tolerate lower QoS levels.


Relative priority model divides traffic into four classes:
• Gold (Mission-Critical)— Transactional, software
• Silver (Guaranteed-Bandwidth)—Streaming video, messaging,
intranet
• Bronze (Best-Effort and Default class)—Internet browsing, E-Mail
• Less-than-Best-Effort (Optional; higher-drop preferences)—FTP,
backups, and applications (MySpace, YouTube, KaZaa)
QoS Traffic Requirements: Voice

• Latency < 150 ms*


• Jitter < 30 ms*
• Loss < 1%*
• 17-106–kbps guaranteed
priority bandwidth
per call
• 150 bps (+ Layer 2
overhead) guaranteed
bandwidth for voice-
control traffic per call
*one-way requirements
QoS Requirements: Videoconferencing

• Latency ≤ 150 ms*


• Jitter ≤ 30 ms*
• Loss ≤ 1%*
• Minimum priority
bandwidth guarantee
required is:
– Video stream + 20%
– For example, a 384 kbps
stream would require
460 kbps of priority
bandwidth
*one-way requirements
QoS Requirements: Video HD
QoS Models
– Best-Effort: No QoS is applied to packets.
– IntServ: Applications signal to the network that they require
special QoS.
– DiffServ: The network recognizes classes that require
special QoS.
Best-Effort Model
– Internet initially based on a best-effort packet delivery
service
– The default mode for all traffic
– No differentiation between types of traffic
– Like using standard mail

(one packet at a time)

(relative time of arrival)


IntServ Model
– Some applications have special
bandwidth or delay requirements or
both
– IntServ introduced to guarantee a
predictable behavior of the network
for these applications
– Guaranteed delivery:
no other traffic can use reserved
bandwidth
– Provides multiple service levels
– Requests specific kind of service from
the network before sending data
– Uses RSVP to reserve network
resources
– Uses intelligent queuing mechanisms
– End to end
IntServ Model

– RSVP QoS services


• Guaranteed-rate service
• Controlled-load service
– RSVP provides policy to QoS mechanisms
DiffServ Model
– Network traffic identified by class
– Network QoS policy enforces differentiated treatment
of traffic classes
– You choose level of service for each traffic class
– Like using a package delivery service
QoS for Converged Networks
Traffic Management
Step 1:
Identify Traffic and Its Requirements

– Network audit
• Identify traffic on the network
– Business audit
• Determine how each type of
traffic is important for
business
– Service levels required
• Determine required
response time
Step 2:
Divide Traffic into Classes
Classification

– Classification is the identifying and splitting of traffic into


different classes.
– Traffic can be classed by various means, including the
DSCP.
– Modular QoS CLI allows classification to be implemented
separately from policy.
– ACLs, NBAR
Network Based Application Reconigtion(NBAR)
Traffic marking techniques
Traffic marking

Data Link Layer:


• Ethernet frame has no fields to signify its QoS
requirements.
• ISL or 802.1Q/P provides a 3 bit Class of Service (CoS)
field.
• Gives Layer 2 switches the ability to prioritize traffic.
Traffic Marking

– Marking, also known as coloring, marks each packet


as a member of a network class so that the packet
class can be quickly recognized throughout the rest of
the network.
DSCP

– DiffServ field: The IP version 4 header ToS octet or the


IPv6 traffic class octet, when interpreted in conformance
with the definition given in RFC 2474
– DSCP: The first six bits of the DiffServ field, used to select
a PHB (forwarding and queuing method)
DSCP

The Differentiated Service Code Point is a selector for


router's per-hop behaviors.
DSCP (like IP Precedence) can be used to provide
differential treatment to packets.
Up to 64 different aggregates/classes can be supported
Default DSCP = 000 000
DSCP Encoding
Mapping DSCP to IP Precedence

CoS 0 1 2 3 4 5 6 7

DSCP 0 8 16 24 32 40 48 56

IP 0 1 2 3 4 5 6 7
Prec
Congestion Management

– Congestion management uses the marking on each


packet to determine in which queue to place packets.
– Congestion management uses sophisticated queuing
technologies, such as WFQ and LLQ, to ensure that
time-sensitive packets such as voice are transmitted first.
Congestion Management
Congestion Avoidance

– Congestion avoidance mechanisms are complementary to (and


dependant on) queuing algorithms.
– Queuing algorithms manage the front of a queue, while
congestion avoidance mechanisms manage the tail of the queue
– Congestion avoidance may randomly drop packets from selected
queues when previously defined limits are reached.
– By dropping packets early, congestion avoidance helps prevent
bottlenecks downstream in the network.
– Congestion avoidance technologies include random early
detection(RED) and weighted random early
detection(WRED).
Congestion Avoidance – Random Early Detection
(RED)

– The basic RED mechanism is to randomly drop


packets before the buffer is completely full.

– Depending on the average queue length, the drop


probability is calculated
Weighted Random Early Detection (WRED)

– WRED combines RED with IP Precedence IP


Precedence to implement multiple service classes.
– Each service class has a defined min and max
thresholds, and drop rates.
Traffic Policing

• Limits traffic flow to a configured bit rate.


• Drops or remarks out-of-profile packets
• Traffic Policing algorithm:
• Token Bucket
Traffic Shaping

• Regulates traffic flow to an average or peak bit rate.


• Commonly used where speed-mismatches exist.
• Traffic shaping algorithm:
• Leaky Bucket
Traffic Policing vs Traffic Shaping
Traffic Policing vs Traffic Shaping
Applying QoS to Input and
Output Interfaces
Modular QoS command line interface (CLI)
The Modular QoS Command Line Interface or MQC is central to
model for implementing IOS based QoS solutions.
The MQC breaks down the tasks associated with QoS into modules
that:
• Identify traffic flows
• Classify traffic flows as belonging to a common class of QoS.
• Apply QoS policies to that class
• Define the interfaces on which the policy should be enforced
Example Modular QoS CLI

Interface Interface Interface


service-policy service-policy service-policy
output policy1 output policy1 output policy2

policy-map policy1 policy-map policy2


class class1 class class1
bandwidth bandwidth
queue-limit queue-limit
random-detect random-detect
class class2 class class3
bandwidth bandwidth
queue-limit queue-limit
random-detect random-detect

class-map class1 class-map class2 class-map class3


match input-interface match access-group match input-interface

access-list
Classification of traffic – The class-map
Router(config)# class-map eietr
Router(config-cmap)#

The class-map command is used to define a traffic class.


• The purpose of a traffic class is to classify or identify traffic
that should be given a particular QoS.
• Traffic that matches a certain criteria.
A traffic class contains three major elements:
• Name
• Series of match commands
• If more than one match command exists in the traffic class an
instruction on how to evaluate these match commands.
Classification of traffic – The class-map
In the example below, any traffic that is “permitted” by the named ACL test will
be considered part of the traffic class known as eietr.

Router(config)# class-map eietr


Rouyer(config-cmap)# match access-group name test

Match commands are used to specify various criteria for classifying


packets.
If a packet matches the specified criteria:
• Packet is considered a member of the class
• Packet is forwarded according to the QoS specifications set in the
traffic policy
Packets that fail to meet any of the matching criteria:
• Classified as members of the default traffic class
• Subject to a separate traffic policy
Classification of traffic – The class-map

If match-any (OR) is specified as the evaluation instruction, the traffic being


evaluated by the traffic class must match one of the specified criteria.
If match-all (AND) is specified as the evaluation instruction, the traffic
being evaluated by the traffic class must match all of the specified
criteria.

Router(config)# class-map match-any eietr


Router(config-cmap)# match access-group name test
Router(config-cmap)# match interface fastethernet 0/1

If traffic matches a permit statement in the ACL test or the


traffic originates from FastEthernet 0/1 then it will be
considered to be part of the class of traffic known as eietr.
Defining the QoS policy – The policy-map

The policy-map command is used to create a traffic policy.


• The purpose of a traffic policy is to configure the QoS
features that should be associated with the traffic that has
been classified in a user-specified traffic class.
A traffic policy contains three elements:
• Policy Name
• Traffic class (specified with the class command)
• QoS policies to be applied to each class
Router(config)# policy-map policy1
Router(config-pmap)# class eietr
Router(config-pmap-c)# bandwidth 3000

Router(config-pmap)# class class-default


Router(config-pmap-c)# bandwidth 2000

The policy-map shown creates a traffic policy named


policy1.
• The policy applies to all traffic classified or identified by the
previously defined traffic-class “eietr”
• Specifies that traffic in this example should be allocated bandwidth of 3000
kbps.
• Any traffic which does not belong to the class “eietr” forms part of the
catch-all class-default class
• Will be given a default bandwidth of 2000 kbps.
Applying the policy to an interface – The service-policy

Router(config)# interface fastethernet 0/1


Router(config-if)# service-policy output policy1

The service policy command is used to attach the traffic


policy, as specified with the policy-map command, to an
interface.
• Can be applied to packets entering or leaving the interface.
Using an IP ACL to define the DSCP or precedence
1. Create the condition criteria.
Router(config)#ip access-list extended 100
Router(config-ext-nacl)#permit tcp any any eq ftp

2. Identify the traffic or traffic flows


Router(config)#class-map controlftp
Router(config-cmap)#match access-group 100

3. Identify the QoS features of a Policy


Router(config)#policy-map cFTP
Router(config-pmap)#class controlftp
Router(config-pmap-c)#set ip dscp 8

4. Attach the traffic policy to an interface.


Router(config)#interface fastethernet 1/0
Router(config-if-range)#service-policy input cFTP
QoS Example

Tasks:
• Mark HTTP traffic from server with DSCP 40 and guarantee 2 Mpbs
priority bandwidth for that traffic.
• Mark FTP traffic from server with DSCP 16 and guarantee 450 Kbps
priority bandwidth for that traffic.
• All other traffic should be marked as DSCP 8
Verify traffic Web Server
Verify traffic FTP Server
Config QoS Policy
Verify Traffic WEB

You might also like