You are on page 1of 54

Training Objectives

HUAWEI

QoS Basic Concept
QoS Model Classification
QoS Features and  Relevent Techniques     
QoS Configuration Commands and 
Debugging

datacomm.huawei.com

Why Should QoS Be Used?
HUAWEI

The current Internet condition is:
 As regards service quality, Internet provides a best-effort model 
through IP network. In this model, the customer cannot be sure of his 
message transferred, be in good or bad, in turn of throughput, delay, 
delay jitter, message dropout rate etc, all depending on the working 
of the network.

What the customer expects of the Internet is:
 The customer expects IP network can guarantee of all the above 
mentioned, so that his special requirement will be met.
 The customer expects tailored quality of services caould be provided

The option between dream and reality is:
 To find a solution to bandwidth deficiency, you could increase 
bandwidth. Yet, there are limitations on bandwidth. Besides you could 
not solve all problems by this way. It is just like an option between 
dream and reality, either be far from reality. So the only solution is 
to enable Internet to provide QoS.

datacomm.huawei.com

HUAWEI

Difinition and Function of
QoS
QoS(Quality of Service):
 QoS refers to a collection of technologies 
dealing with such features as throughput, 
delay, delay jitter, and packet loss rate.
QoS provides such functions:
Message Classification
Congestion Management and Prevention
Traffic policing and shaping.
 Limit Physical Interface Bandwidth

datacomm.huawei.com

Three QoS Service Model
HUAWEI

Best-effort:
Best-effort model do not ensure the quality of service

Integrated service:
Adopting signaling mechanism network could notify intermediate
routers to preserve resources needed. However, in a larger 
network this model itself will exhaust more resources. 
Therefore, this model is generally applied to the edge of the 
network.

Differentiated service:
This service mode classifies jobs of similar requirement, and 
provides
defferent
service
quaility.
Based
on
the 
classification, it is capable of scheduling message transfer 
according to whether the message is located on the edge  or at 
the core of the network system  with no need for any special 
signaling support. 

datacomm.huawei.com

HUAWEI

Int-serv: Integrated Service
Model
The signaling that carries QoS requests is RSVP, 
which notifies the router QoS request from an 
application.
Int-serv mode provides two types of service:
Guarantee Service: this service provides guaranteed bandwidth 
and  timedelay limit to satisfy the need of the applications.
Load Control Service: In case of network overload,  the  service 
guarantees to provide the message with  a service, that is close 
to that offered when the network is not overloaded. That is, it 
guarantees subnormal delay and high speed passage for some 
applications programs even when network congestion occurs.

datacomm.huawei.com

HUAWEI Diff-serv: Different Service Model With no need of any signaling support,  this mode  implements packets classification, flow shaping,  flow policing and queuing by means of some character  of IP packets.  The model adopts following technologies to provide  important applications with end-to-end QoS  guarantee CAR: Executes packets classification according to the IP data  packet precedence or QoS group.  Queuing Technologies: PQ CQ WFQ used for packet output management. CBWFQ queuing technology are  MPLS: shim technology and label technology datacomm.huawei.com .

HUAWEI QoS Features and Technologies HUAWEI VRP QoS has such features: Packet Classify Congestion Management Congestion Avoidance Flow Management and Flow Shaping Signaling Resource preserve ATM Interface QoS datacomm.com .huawei.

huawei.Message Classification HUAWEI  Packet Classification TOS Field of IP packet header Data link layer, Network layer, Transportation  layer information can be used. Generally use the IP header information for  classification  Technologies:  ACL and IP precedence datacomm.com .

HUAWEI Service Quality--Congestion Management What if network is congested?(see the example on the  next page) Increasing bandwidth--avoid congestion But it is restricted by cost and constructing time. Adopting queue congestion management to relleviate   Adopt queue mechanism to manage the congestion, such as  FIFO PQ CQ WFQ CBWFQ. Queue mechanism: when congestion occurs,packets will be  buffered into output queues of the router according to specific  polices. When the interface sould send packets, all packets will  be sent in the order determined by specific polices. datacomm.com .huawei.

QoS--Congestion Control HUAWEI Frame Relay/X.25/DDN 2 M serial 1 router2 PC2 Ethernet 2 M 10 M serial 1 Public Network 2 PC1 router1 Server2 Ethernet 10 M Server1 Public Network 1 datacomm.com .huawei.

com .HUAWEI Congestion Management--Queue Mechanism According to the different policy of queue  and dequeue,congestion management can be  divided as follows: FIFO First In First Out    PQ Priority Queue          CQ Custom Queue          WFQ Weighted Fair Queue) CBWFQ Class Based WFQ) datacomm.huawei.

huawei.HUAWEI Congestion Management--FIFO FIFO: Namely first in and first out queue,  packet queue sequence packet to message  dequeue sequence. queue data packet need to be sent out through this interface data packet sent from interface dequeue schedue prcess datacomm.com .

com .huawei.HUAWEI Congestion Management--PQ PQ: Namely priority queue, can assure  bandwidth and time-delay of high priority  queues. PQ is divided into 4 queues: High, Medium, Normal and  Low High precedence queues first dispatched. The rule of message inserting into queuing can be  configurated datacomm.

com .HUAWEI Congestion Management--CQ CQ Custom  Queueing,  that  is  the  user  can configurate the proportion of bandwidth each queue  take up: CQ can be support 17 queues: Queue0 is system queue, it will be  dispatched firstly; Queue1 to Queue16 are user queues,  dispatching bandwidth by polling; Statisticly, each queue satisfies bandwidth that the user  configurates; The rule of entering queue can be configurated; datacomm.huawei.

HUAWEI Congestion Management--WFQ WFQ: Weighted Fair Queue,assures justice to services  with identical priority,and give different weight to  services with different priority Maximum number of queues can be confiigured. 16-4096 ; Use HASH algorithm to dispatch the different flows into different queues.This  process is automaticly done; On the basis of justice(bandwidth,delay),give different weight tp services  with defferent priority; The weight depend on the precedence of the IP packet; queue queue 1 data packet sent from this interface queue 2 data packet need to be sent from this interface queue N ... classify dequeue dispatch datacomm.huawei.com .

CBWFQ CBWFQ: Class Based WFQ Classification number can be configured (1-64) Data flows enter corresponding queues according to the  user configuration. Data flows couldn't match any preconfigured rules will  go into the default queue when WFQ dispatch mechanism or  FIFO is applied Dispatching algorithm assures classified queues of  reserved bandwidth, default queues share remaining  bandwidth  datacomm.HUAWEI CBWFQ Congestion Management -.huawei.com .

CBWFQ Diagrammatic HUAWEI queue queue 0 priority queue queue 1 queue 2 ... packet sent from this interface queue N1 classify packet need to be sent from this interface default queue dequeue dispatch queue 1 queue 2 ... queue N2 datacomm.com .huawei.

com .huawei.Congestion Avoidence HUAWEI WRED(Weighted Random Early Detection) WRED can predict possible congestions by the current  condition and prevent congestion from occuring  by  restricting some of TCP connections WRED can prevent TCP golbal synchronization by using  randam dropout method Dispatch algorithm could let the classified queues can get  the reserved bandwidth and the default queues can share  the redundant bandwidth datacomm.

Congestion Prevention HUAWEI The user can set the upper limit and  the lower  bound of the queue limit. When the length of the  queue is under the lower limit, no dropout occurs.  When it is between lower limit and the upper limit,  WRED begins to drop out packets  randomly. When the  length is above the upper limit, all packets will be  dropped out. WRED queue queue 1 packets sent from this interface queue 2 packets need to be sent from this dropout interface ... auto-classify dequeue dispatch queue N datacomm.huawei.com .

HUAWEI Packets Classification and Flow Policing Why we need packets classification? Packets classification on the edge of a network facilitate the  Diff-Serv realization of nodes within the network Why we need flow policing? It is high necessary for the Internet Service Provider(ISP) to police  the flow a user sends to the net. With regard to a company network,if it can police certain application  flow, it will also be an important method fornetwork management Policing network load datacomm.huawei.com .

com .huawei.Flow Policing(CAR) HUAWEI CAR,Committed Access Rate CAR is responsible for policing flow by means of a  Tocken Bucket(TB) classify TB continue transmit dropout datacomm.

huawei.com .Flow Shaping HUAWEI GTS Generic Traffic Shaping , Traffic Shaping The flow on the interface can be constrained by configured flow  feaure. This helps to make sure of coorperation among various jobs  and  coorperation between downstream and upstream node,it also  helps to reduce packet loss rate and thus improve service  quality.  Implemetation methods:Control  packets flowrate, Buffer the packets  beyond flowrate restraint, and then transmit the buffered  packets  at a propriety time. drop tockens at a certain speed classify packet need to be sent from this interface transmit queue TB datacomm.

HUAWEI Limit Speed on Physical Interface LR(Line Rate), Speed limits on the phisical interface   During the period of network construction, medium and long term  needs should be taking into account.While in actual  operation,the network service is tailored based on the bandwidth  the user buyed, so that the invester's interests are  protected.The control ability and management ability are  enhanced.  drop tockens at a certain speed LR QOS Queue TB transmit packets need to be sent from this interface in-buffer datacomm.huawei.com .

huawei.Configuration of FIFO HUAWEI FIFO Queue Configuration Method: FIFO has no rule base,so FIFO is directly used under the  interface configuration mode, also specified the queue  length. Example: The below command apply FIFO on the Ethernet 0 the queue length to 50 at the same time Set Quidway(config-if-Ethernet0)#fifo-queue-limit 50 datacomm.com .

com .huawei.Configurations of PQ HUAWEI PQ configurations: Create PQ rule base PQ Lists, PQL At most 16 groups can be created. Each rule group defines complete  the complete behavior of a priority qeue( how to classify, what is  the queue length, which queue is the default queue); Apply PQ on the interface Apply PQ under the interfaceconfiguration mode,also specify the  behavior of the PQ for be in using is defined by which rule group  in the rule base datacomm.

Create PQRule Group HUAWEI Rule group should include: Default queue rule Rule of each queue length upper bound Some( 0 to 100) packets classification rules datacomm.huawei.com .

com .Create PQRule Group HUAWEI Define default queue rule That is to define in whcih queue a packetthey should be put  when the it does not conform to any rule p r i o r i t y - l i s t   group-number  d e f a u l t   {h i g h | m e d i u m | n o r m a l | l o w } n o  p r i o r i t y - l i s t  group-number d e f a u l t Example: The default queue rule that the below command  appoints in PQ rule base group 1 is:the low queue is  the default queue Quidway(config)#priority-list 1 default low datacomm.huawei.

Create PQ Rule Group HUAWEI Definie queue length upper bound rule p r i o r i t y - l i s t  group-number q u e u e - l i m i t  high-limit   medium-limit  normal-limit  low-limit  n o   p r i o r i t y - l i s t   group-number q u e u e - l i m i t   Example:  Below command designates the queue length upper bound for  rule group 1 of PQ rule base: high=15 medium=20 normal=50 low=100 Quidway(config)#priority-list 100 1 queue-limit 15  20  50  datacomm.huawei.com .

Create PQ Rule Group HUAWEI Define packet classification rule according to  interface That is, define which queue they should be put into p r i o r i t y - l i s t   group-number i n t e r f a c e   interface-type   interface-number { h i g h | m e d i u m | n o r m a l | l o w } no  priority-list  group-number  interface  interface-type interface-number  Example: A packet classification rule of Group 1 in rule base that  below command designated is: Packets receieved from serial  0 will be put into the medium queue Quidway(config)#priority-list medium 1 interface serial datacomm.huawei.com 0   .

Create PQ Rule Group HUAWEI Define packet classification rule  according to protocol information That is, define which queue they should be put into  p r i o r i t y - l i s t     group-number p r o t o c o l   protocol-name  h i g h | m e d i u m | n o r m a l | l o w }   queue-keyword  keyword-value n o     p r i o r i t y - l i s t     group-number p r o t o c o l   protocol-name  h i g h | m e d i u m | n o r m a l | l o w }   queue-keyword  keyword-value datacomm.com .huawei.

huawei.com .Apply PQ on the Interface HUAWEI Apply PQ on the Interface p r i o r i t y - g r o u p   group-number no priority-group Example: Below command apply PQ on the interface Ethernet 0, then  apply rule 10 of PQ rule base to define PQ behavior on  the interface Quidway(config-if-Ethernet0)#priority-group 10 datacomm.

huawei.Configurations of CQ HUAWEI CQ configurations process: Create CQ rule group CQ Lists,CQL That is, create the rule base of CQ. Rule base can totally creat  16 rule groups. Each rule group defines complete behavior of CQ  ( how to classify packets, how long each queue is,which queue is  the default queue,what proportion of of bandwidth are allocated  to each queue )  Apply CQ on the interface Apply CQ under the interface configuration mode, and also  specify which rule group in the rule base defined the behavior  of CQ datacomm.com .

Create PQ Rule Group HUAWEI A rule group should include: Default queue rule Rule of each queue length upper bound Rule of each queue's share of bandwidth Some(0 to 100 ) Packet classification rule datacomm.huawei.com .

huawei.com .  Create PQ Rule Group HUAWEI Define Default Queue  Rule Namely define which queue should the message entry when  it does not match any existent rule c u s t o m - l i s t     group-number d e f a u l t   queue-number n o   c u s t o m - l i s t   group-number d e f a u l t   Parameter statement: group-number number of CQ rule group 1 16 queue-number 17 queues correspond to CQ 0 16 Example: Below command designate default queue rule in  group 1 of CQ rule base: Queue 1 is the default  queue. datacomm.

com .huawei.Create CQ Rule Group HUAWEI Define upper bound length of the queue c u s t o m - l i s t   group-number q u e u e   queue-number l i m i t   queue-limit n o     c u s t o m - l i s t     group-number q u e u e   queue-number  l i m i t   Example: Below command designates the length upper bound of the  queue in CQ rule base group 1: Max queue length of CQ queue  10 is 40. Quidway(config)#custom-list 1 queue 10 limit 40 datacomm.

huawei.com .Create CQ Rule Base HUAWEI Define rule eath queue bandwidth proportion  c u s t o m - l i s t   group-number q u e u e   queue-number b y t e - c o u n t   byte-count-number no c u s t o m - l i s t   group-number byte-count q u e u e   queue-number  Quidway(config)#custom-list 1 queue 10 byte-count  500 datacomm.

Create CQ Rule Group HUAWEI Define packet claaification according to interface rule  That is to define which queue should them to be sent  into  c u s t o m - l i s t   group-number i n t e r f a c e   interface-type  interface-number  queue-number no c u s t o m - l i s t   group-number interface-type  interface-number  interface  Example: Below command designates a packet classification  rule in group 1 of CQ rule base: put packets come  from serial 0 enter Queue 2 datacomm.huawei.com .

Create CQRule Group HUAWEI Define packet classification rule by  protocol information c u s t o m - l i s t     group-number p r o t o c o l   protocol-name   queue-number  queue-keyword  keyword-value n o     c u s t o m - l i s t     group-number p r o t o c o l   protocol-name  queue-number  queue-keyword  keyword-value                                datacomm.huawei.com .

huawei.Apply CQ on Interface HUAWEI Apply CQ on Interface c u s t o m - g r o u p   group-number no custom-group Example: Below command apply CQ on Erthenet 0, and use  rule group 10 in the CQ rule base to difine CQ  behavior on the interface Quidway(config-if-Ethernet0)#custom-group 10 datacomm.com .

Configuration of WFQ HUAWEI WFQ configuration Method: WFQ has no rule base,so it should be used  derectly in the interface mode, at the same time  it can set the length and number of the queues. Example: Below command use WFQ on Ethernet 0, and set the  length of the queue to 50(Number of the queue  need not be appoint, use the default value 256) Quidway(config-if-Ethernet0)#fair-queue 50 datacomm.huawei.com .

huawei.Configuration of WRED HUAWEI WRED configuration process: Apply WRED on the interface WRED must be used with WFQ, so WFQ should set at first Modify the WRED requirement parameter according to the  After set WRED, we can modify its relevant parameter  (filtering index, probability denominator, max-threshold,  min-threshold)  datacomm.com .

Configurations of WRED HUAWEI WRED configuration method: Example: Below command apply WRED on Ethernet 0,then set  filtering index as 5,max-threshold of packets  with precedence 7 as 60, min-threshold as 20,  dropput probability denominator as 100 ( suppose  the interface have already been applied WFQ) Quidway(config-if-Ethernet0)#random-detect Quidway(config-if-Ethernet0)#random-detect  exponent-weighting-constant 5 Quidway(config-if-Ethernet0)#random-detect  datacomm.com .huawei.

huawei.com .Configurations of CAR HUAWEI CAR configuration process: Create CAR rule CAR Lists, CARL Namely create CAR rule base. Rule base can create 199  rules mostly. One rule difines one kind of  packets. Apply CAR on the interface Apply CAR under the interface configuration mode,and  also point out by what means ( can be CARL or ACL)Car  used to classify the packets and what action will be  applied to these packets after the classification. datacomm.

Create CARrule HUAWEI Create CAR rule This command is used to define CAR rule base.We can create  99 rules mostly. Each rule defines one kind of packets. a c c e s s - l i s t     r a t e - l i m i t   access-list mac-address |   m a s k   prec-mask} { precedence |  n o   a c c e s s - l i s t   r a t e - l i m i t   access-list  Example: B e l o w c o m m a n d d e s i g n a t e C A R r u l e 1 a s :   messages which  precedence is 1 , 2 , 3   m a t c h   t h i s   r u l e Quidway(config)#access-list rate-limit 1 mask 42 datacomm.huawei.com .

Create CARrule HUAWEI Apply CAR on the interface By this command,we can apply CAR on the interface for  packet classification and flow policing.The classification  rule could be  CARL,  also could be ACL rate-limit {input|output} [access-group [rate-limi access-list]   bps  burst-size  excess-burst-size  c o n f o r m - a c t i o n   action e x c e e d - a c t i o n   action no rate-limit {input|output} [access-gro [ r a t e - l i m i t ]   access-list]   bps  burst-size  excess-burst-size c o n f o r m - a c t i o n   action e x c e e d - a c t i o n action                datacomm.com .huawei.

huawei.Configuraion of GTS HUAWEI GTS configuration has two types: Configure packets GTS on the interface, shaping all Configure GTS on the interface, shaping one spec packet datacomm.com .

huawei.Configuraion of GTS HUAWEI Shape all the packets: traffic-shape g r o u p   access-list  bps  [burst-size  [excess-burst-size  [queue-limit]]]  n o   t r a f f i c - s h a p e   g r o u p   access-list Example: The below command enable the GTS on the Ethernet 0, all the flows sent by the interface: The flow is not than 54000 bps, and it can have a double outburst; length of GTS buffer queue is 1000 Quidway(config-if-Ethernet0)#trafic-shape 54000  0  1000 datacomm.com rate .

Configuraion of GTS HUAWEI Shape specific message: traffic-shape g r o u p   access-list  bps  [burst-size  [excess-burst-size  [queue-limit]]]  n o   t r a f f i c - s h a p e   g r o u p   access-list Example: The below command enable GTS on the Ethernet 0, it wi shape the packets sent out by the interface which a matched ACL rule 122 : the flow is not greater th 54000 bps, and it can have one outburst; the max leng of GTS buffer queue is 1000 Quidway(config-if-Ethernet0)#trafic-shape 54000  54000  0  1000 group datacomm.huawei.com .

Configuration of LR HUAWEI Directly be in use under the interface mode, a specify the parameter at the same time line-rate bps [burst-size [excess-burst-size]] no line-rate Example: Below command use LR on the Ethernet 0, then cut inter bandwidth to 54000 bps, and can have a doubl outburst. Quidway(config-if-Ethernet0)#line-rate 54000  54000  datacomm.com .huawei.

com .huawei.Configuration of LR HUAWEI Directly be in use under the interface mode, a specify the parameter at the same time line-rate bps [burst-size [excess-burst-size]] no line-rate Example: Below command use LR on the Ethernet 0, then cut inter bandwidth to 54000 bps, and can have a doubl outburst. Quidway(config-if-Ethernet0)#line-rate 54000  54000  datacomm.

Configuration of LR HUAWEI Directly be in use under the interface mode, a specify the parameter at the same time line-rate bps [burst-size [excess-burst-size]] no line-rate Example: Below command use LR on the Ethernet 0, then cut inter bandwidth to 54000 bps, and can have a doubl outburst. Quidway(config-if-Ethernet0)#line-rate 54000  54000  datacomm.com .huawei.

com .huawei.QoS SHOW Command HUAWEI show  queueing  [ priority custom ] Show PQ and CQ rule base The show method has:Only show the PQ; Only show the Show the PQ and CQ at the same time Example: Below command show all rules of current PQ and CQ r base. Quidway(config)#show queueing  datacomm.

com .QoS SHOW Command HUAWEI show  access-list rate-limit  [ access-list ] Show CAR rule base. The show method has:Only show a certain CAR rule;S all CAR rules at the same time Example: The below command shows the 13 CAR rule. Quidway(config)#show  access-list  rate-limit 13 datacomm.huawei.

huawei.QoS SHOW Command HUAWEI s h o w     q o s - i n t e r f a c e     [   interface-type  interface-number ]  priority-queue   custom-queue   fair-queue  random-detect traffic-shape  line-rate Show the run-time data for each QoS characteristic  appli current interface. We can choose to show the run-time data of a certai characteristic of some interfaces or to Show a certain characteristic in the run-time data of all interfaces Example: Below command shows all interfaces PQ run-time data. Quidway(config)#show  qos-interface  priority-queue datacomm.com .