Katz, Stoica F04 EECS 122: Introduction to Computer Networks Packet Scheduling and QoS Computer Science Division Department of Electrical Engineering and.

Slides:



Advertisements
Similar presentations
CS 268: Packet Scheduling Ion Stoica March 18/20, 2003.
Advertisements

1 CNPA B Nasser S. Abouzakhar Queuing Disciplines Week 8 – Lecture 2 16 th November, 2009.
Abhay.K.Parekh and Robert G.Gallager Laboratory for Information and Decision Systems Massachusetts Institute of Technology IEEE INFOCOM 1992.
Courtesy: Nick McKeown, Stanford 1 Intro to Quality of Service Tahir Azim.
CS 268: Lecture 8 Router Support for Congestion Control Ion Stoica Computer Science Division Department of Electrical Engineering and Computer Sciences.
Real-Time Protocol (RTP) r Provides standard packet format for real-time application r Typically runs over UDP r Specifies header fields below r Payload.
CS 4700 / CS 5700 Network Fundamentals Lecture 12: Router-Aided Congestion Control (Drop it like it’s hot) Revised 3/18/13.
Ion Stoica, Scott Shenker, and Hui Zhang SIGCOMM’98, Vancouver, August 1998 subsequently IEEE/ACM Transactions on Networking 11(1), 2003, pp Presented.
Differentiated Services. Service Differentiation in the Internet Different applications have varying bandwidth, delay, and reliability requirements How.
A Case for Relative Differentiated Services and the Proportional Differentiation Model Constantinos Dovrolis Parameswaran Ramanathan University of Wisconsin-Madison.
Worst-case Fair Weighted Fair Queueing (WF²Q) by Jon C.R. Bennett & Hui Zhang Presented by Vitali Greenberg.
CS 268: Lecture 15/16 (Packet Scheduling) Ion Stoica April 8/10, 2002.
Networking Issues in LAN Telephony Brian Yang
Generalized Processing Sharing (GPS) Is work conserving Is a fluid model Service Guarantee –GPS discipline can provide an end-to-end bounded- delay service.
Service Disciplines for Guaranteed Performance Service Hui Zhang, “Service Disciplines for Guaranteed Performance Service in Packet-Switching Networks,”
Katz, Stoica F04 EECS 122: Introduction to Computer Networks Performance Modeling Computer Science Division Department of Electrical Engineering and Computer.
CS 268: Differentiated Services Ion Stoica February 25, 2003.
CS 268: Lecture 8 (Router Support for Congestion Control) Ion Stoica February 19, 2002.
CSE 401N Multimedia Networking-2 Lecture-19. Improving QOS in IP Networks Thus far: “making the best of best effort” Future: next generation Internet.
Router Design and Packet Scheduling
CS 268: Integrated Services Ion Stoica February 23, 2004.
1 CS 194: Distributed Systems Resource Allocation Scott Shenker and Ion Stoica Computer Science Division Department of Electrical Engineering and Computer.
CS144, Stanford University Error in Q3-7. CS144, Stanford University Using longest prefix matching, the IP address will match which entry? a /8.
Packet Scheduling From Ion Stoica. 2 Packet Scheduling  Decide when and what packet to send on output link -Usually implemented at output interface 1.
CIS679: Scheduling, Resource Configuration and Admission Control r Review of Last lecture r Scheduling r Resource configuration r Admission control.
Integrated Services (RFC 1633) r Architecture for providing QoS guarantees to individual application sessions r Call setup: a session requiring QoS guarantees.
CSE679: QoS Infrastructure to Support Multimedia Communications r Principles r Policing r Scheduling r RSVP r Integrated and Differentiated Services.
CSE QoS in IP. CSE Improving QOS in IP Networks Thus far: “making the best of best effort”
CS640: Introduction to Computer Networks Aditya Akella Lecture 20 - Queuing and Basics of QoS.
CONGESTION CONTROL and RESOURCE ALLOCATION. Definition Resource Allocation : Process by which network elements try to meet the competing demands that.
Advance Computer Networking L-5 TCP & Routers Acknowledgments: Lecture slides are from the graduate level Computer Networks course thought by Srinivasan.
Fair Queueing. 2 First-Come-First Served (FIFO) Packets are transmitted in the order of their arrival Advantage: –Very simple to implement Disadvantage:
March 29 Scheduling ?. What is Packet Scheduling? Decide when and what packet to send on output link 1 2 Scheduler flow 1 flow 2 flow n Buffer management.
Network Support for QoS – DiffServ and IntServ Hongli Luo CEIT, IPFW.
CS640: Introduction to Computer Networks Aditya Akella Lecture 20 - Queuing and Basics of QoS.
Nick McKeown Spring 2012 Lecture 2,3 Output Queueing EE384x Packet Switch Architectures.
Packet Scheduling: SCFQ, STFQ, WF2Q Yongho Seok Contents Review: GPS, PGPS SCFQ( Self-clocked fair queuing ) STFQ( Start time fair queuing ) WF2Q( Worst-case.
EE 122: Lecture 15 (Quality of Service) Ion Stoica October 25, 2001.
1 Multimedia Networking: Beyond Best-Effort Internet.
T. S. Eugene Ngeugeneng at cs.rice.edu Rice University1 COMP/ELEC 429 Introduction to Computer Networks Lecture 18: Quality of Service Slides used with.
CprE 458/558: Real-Time Systems (G. Manimaran)1 CprE 458/558: Real-Time Systems Real-Time Networks – WAN Packet Scheduling.
Scheduling Determines which packet gets the resource. Enforces resource allocation to each flows. To be “Fair”, scheduling must: –Keep track of how many.
T. S. Eugene Ngeugeneng at cs.rice.edu Rice University1 COMP/ELEC 429/556 Introduction to Computer Networks Weighted Fair Queuing Some slides used with.
1 Fair Queuing Hamed Khanmirza Principles of Network University of Tehran.
Queue Scheduling Disciplines
Katz, Stoica F04 EECS 122: Introduction to Computer Networks Midterm II Review Computer Science Division Department of Electrical Engineering and Computer.
Spring Computer Networks1 Congestion Control Sections 6.1 – 6.4 Outline Preliminaries Queuing Discipline Reacting to Congestion Avoiding Congestion.
Providing QoS in IP Networks
Univ. of TehranIntroduction to Computer Network1 An Introduction Computer Networks An Introduction to Computer Networks University of Tehran Dept. of EE.
Scheduling for QoS Management. Engineering Internet QoS2 Outline  What is Queue Management and Scheduling?  Goals of scheduling  Fairness (Conservation.
1 Lecture 15 Internet resource allocation and QoS Resource Reservation Protocol Integrated Services Differentiated Services.
04/02/08 1 Packet Scheduling IT610 Prof. A. Sahoo KReSIT.
QoS & Queuing Theory CS352.
EE 122: Router Support for Congestion Control: RED and Fair Queueing
Quality of Service For Traffic Aggregates
COMP/ELEC 429/556 Introduction to Computer Networks
Variations of Weighted Fair Queueing
Fair Queueing.
EE 122: Quality of Service and Resource Allocation
Computer Science Division
EE 122: Lecture 7 Ion Stoica September 18, 2001.
Variations of Weighted Fair Queueing
EECS 122: Introduction to Computer Networks Midterm II Review
COMP/ELEC 429 Introduction to Computer Networks
Introduction to Packet Scheduling
EECS 122: Introduction to Computer Networks Packet Scheduling and QoS
Fair Queueing.
Introduction to Packet Scheduling
کنترل جریان امیدرضا معروضی.
Presentation transcript:

Katz, Stoica F04 EECS 122: Introduction to Computer Networks Packet Scheduling and QoS Computer Science Division Department of Electrical Engineering and Computer Sciences University of California, Berkeley Berkeley, CA

Katz, Stoica F04 2 Today’s Lecture: 15 Network (IP) Application Transport Link Physical 2 7, 8, 9 10,11 17, 18, 19 14, 15, 16 21, 22,

Katz, Stoica F04 3 Packet Scheduling  Decide when and what packet to send on output link -Usually implemented at output interface of a router 1 2 Scheduler flow 1 flow 2 flow n Classifier Buffer management

Katz, Stoica F04 4 Goals of Packet Scheduling  Provide per flow/aggregate QoS guarantees in terms of delay and bandwidth  Provide per flow/aggregate protection  Flow/Aggregate identified by a subset of following fields in the packet header -source/destination IP address (32 bits) -source/destination port number (16 bits) -protocol type (8 bits) -type of service (8 bits)  Examples: -All packets from machine A to machine B -All packets from Berkeley -All packets between Berkeley and MIT -All TCP packets from EECS-Berkeley

Katz, Stoica F04 5 Outline  QoS guarantees  Link sharing  Service curve (short)

Katz, Stoica F04 6 Recap: Token Bucket and Arrival Curve  Parameters -r – average rate, i.e., rate at which tokens fill the bucket -b – bucket depth -R – maximum link capacity or peak rate (optional parameter)  A bit is transmitted only when there is an available token  Arrival curve – maximum number of bits transmitted within an interval of time of size t r bps b bits <= R bps regulator time bits b*R/(R-r) slope R slope r Arrival curve

Katz, Stoica F04 7 How Is the Token Bucket Used?  Can be enforced by -End-hosts (e.g., cable modems) -Routers (e.g., ingress routers in a Diffserv domain)  Can be used to characterize the traffic sent by an end-host

Katz, Stoica F04 8 Source Traffic Characterization  Arrival curve – maximum amount of bits transmitted during an interval of time Δt  Use token bucket to bound the arrival curve ΔtΔt bits Arrival curve time bps

Katz, Stoica F04 9 Source Traffic Characterization: Example  Arrival curve – maximum amount of bits transmitted during an interval of time Δt  Use token bucket to bound the arrival curve bits Arrival curve time bps (R=2,b=1,r=1) ΔtΔt

Katz, Stoica F04 10 QoS Guarantees: Per-hop Reservation  End-host: specify -the arrival rate characterized by token-bucket with parameters (b,r,R) -the maximum maximum admissible delay D  Router: allocate bandwidth r a and buffer space B a such that -no packet is dropped -no packet experiences a delay larger than D bits b*R/(R-r) slope r Arrival curve D BaBa slope r a

Katz, Stoica F04 11 Packet Scheduling  Make sure that at any time the flow receives at least the allocated rate r a  The canonical example of such scheduler: Weighted Fair Queueing (WFQ)

Katz, Stoica F04 12 Recap: Fair Queueing  Implements max-min fairness: each flow receives min ( r i, f ), where -r i – flow arrival rate -f – link fair rate (see next slide)  Weighted Fair Queueing (WFQ) – associate a weight with each flow

Katz, Stoica F04 13 Fair Rate Computation: Example 1  If link congested, compute f such that f = 4 : min(8, 4) = 4 min(6, 4) = 4 min(2, 4) = 2 10

Katz, Stoica F04 14 Fair Rate Computation: Example 2  Associate a weight w i with each flow i  If link congested, compute f such that f = 2 : min(8, 2*3) = 6 min(6, 2*1) = 2 min(2, 2*1) = 2 10 ( w 1 = 3) ( w 2 = 1) ( w 3 = 1) If Σ k w k = w i Flow i is guaranteed to be allocated a rate >= wi *C/( Σ k w k )

Katz, Stoica F04 15 Fluid Flow System  Flows can be served one bit at a time  WFQ can be implemented using bit-by-bit weighted round robin -During each round from each flow that has data to send, send a number of bits equal to the flow’s weight

Katz, Stoica F04 16 Fluid Flow System: Example Flow 2 (arrival traffic) Flow 1 (arrival traffic) Service in fluid flow system time time (ms) Packet Size (bits) Packet inter-arrival time (ms) Rate (Kbps) Flow Flow Kbps Flow 1 ( w 1 = 1) Flow 2 ( w 2 = 1)

Katz, Stoica F04 17 Fluid Flow System: Example  Red flow has packets backlogged between time 0 and 10 -Backlogged flow  flow’s queue not empty  Other flows have packets continuously backlogged  All packets have the same size flows link weights

Katz, Stoica F04 18 Implementation In Packet System  Packet (Real) system: packet transmission cannot be preempted. Why?  Solution: serve packets in the order in which they would have finished being transmitted in the fluid flow system

Katz, Stoica F04 19 Packet System: Example Packet system time Service in fluid flow system time (ms)  Select the first packet that finishes in the fluid flow system

Katz, Stoica F04 20 Packet System: Example  Select the first packet that finishes in the fluid flow system Service in fluid flow system Packet system

Katz, Stoica F04 21 Implementation Challenge  Need to compute the finish time of a packet in the fluid flow system…  … but the finish time may change as new packets arrive!  Need to update the finish times of all packets that are in service in the fluid flow system when a new packet arrives -But this is very expensive; a high speed router may need to handle hundred of thousands of flows!

Katz, Stoica F04 22 Example  Four flows, each with weight 1 Flow 1 time ε Flow 2 Flow 3 Flow Finish times computed at time 0 time Finish times re-computed at time ε 01234

Katz, Stoica F04 23 Solution: Virtual Time  Key Observation: while the finish times of packets may change when a new packet arrives, the order in which packets finish doesn’t! -Only the order is important for scheduling  Solution: instead of the packet finish time maintain the number of rounds needed to send the remaining bits of the packet (virtual finishing time) -Virtual finishing time doesn’t change when the packet arrives  System virtual time – index of the round in the bit-by-bit round robin scheme

Katz, Stoica F04 24 System Virtual Time: V(t)  Measure service, instead of time  V(t) slope – normalized rate at which every backlogged flow receives service in the fluid flow system -C – link capacity -N(t) – total weight of backlogged flows in fluid flow system at time t Service in fluid flow system time V(t)

Katz, Stoica F04 25 System Virtual Time (V(t)): Example 1  V(t) increases inversely proportionally to the sum of the weights of the backlogged flows Flow 2 (w2 = 1) Flow 1 (w1 = 1) time C C/2V(t)

Katz, Stoica F04 26 System Virtual Time: Example w1 = 4 w2 = 1 w3 = 1 w4 = 1 w5 = 1 C/4 C/8 C/4 V(t)

Katz, Stoica F04 27 Fair Queueing Implementation  Define - - virtual finishing time of packet k of flow i - - arrival time of packet k of flow i - - length of packet k of flow i -w i – weight of flow i  The finishing time of packet k+1 of flow i is / w i

Katz, Stoica F04 28 Properties of WFQ  Guarantee that any packet is transmitted within packet_lengt/link_capacity of its transmission time in the fluid flow system -Can be used to provide guaranteed services  Achieve max-min fair allocation -Can be used to protect well-behaved flows against malicious flows

Katz, Stoica F04 29 Outline  QoS guarantees  Link sharing  Service curve (short)

Katz, Stoica F04 30 Hierarchical Link Sharing  Resource contention/sharing at different levels  Resource management policies should be set at different levels, by different entities -Resource owner -Service providers -Organizations -Applications Link Provider 1 seminar video Math Stanford.Berkeley Provider 2 WEB 155 Mbps 50 Mbps 10 Mbps 20 Mbps 100 Mbps 55 Mbps Campus seminar audio EECS

Katz, Stoica F04 31 Hierarchical WFQ (H-WFQ) Example  Red session has packets backlogged at time 5  Other sessions have packets continuously backlogged First red packet arrives at 5…and it is served at 7.5 Service in fluid flow system

Katz, Stoica F04 32 Packet Approximation of H-WFQ  Idea 1 -Select packet finishing first in H-WFQ assuming there are no future arrivals -Problem: Finish order in system dependent on future arrivals Virtual time implementation won’t work  Idea 2 -Use a hierarchy of WFQ to approximate H-WFQ WFQ 10 Packetized H-WFQ Fluid Flow H-WFQ WFQ 10

Katz, Stoica F04 33 Problems with Idea 1  The order of the 4 th blue packet finish time and of the first green packet finish time changes as a result of a red packet arrival Make decision here Blue packet finish first Green packet finish first

Katz, Stoica F04 34 Problem with Idea 2  A packet on the second level can miss its deadline (finish time) First red packet arrives at 5 …but it is served at 11 ! First level packet schedule Second level packet schedule

Katz, Stoica F04 35 Solution  Hierarchical-WFQ with a better implementation of WFQ, called Worst-Case Weighted Fair Queueing (WF2Q)  Main idea of WF2Q -Consider for scheduling only eligible packets -Eligible packet at time t: a packet that has started being serviced in the fluid flow system at time t

Katz, Stoica F04 36 Example Fluid-Flow System WFQ (smallest finish time first) WF2Q (smallest eligible finish time first)

Katz, Stoica F04 37 Hierarchical-WF2Q Example  In WF2Q, all packets meet their deadlines modulo time to transmit a packet (at the line speed) at each level First red packet arrives at 5..and it is served at 7 First level packet schedule Second level packet schedule

Katz, Stoica F04 38 Outline  QoS guarantees  Link sharing  Service curve (short)

Katz, Stoica F04 39 Bandwidth-Delay Coupling  Assume -An arrival curve specified by token bucket (R, r, b) -A reservation request (r min, D), where r min – minimum bandwidth, D – maximum delay  WFQ can be inefficient: to satisfy delay D, the allocated rate r a may need to be much higher than r ! bits b*R/(R-r) slope r Arrival curve slope r a D

Katz, Stoica F04 40 Example  End-host: request a worst-case delay D=10ms for a flow characterized by token bucket (R=1Mbps, b=10Kb, r=100Kbps)  Router: allocate rate r a, where  Thus, the router needs to allocate to the flow more than 5 times its average rate r ! r a = b*R / (D*(R-r) + b) = 0.52Mbps

Katz, Stoica F04 41 Solution: Service Curve  Generalize the service allocated to a flow -Assume a flow that is idle at time s and it is backlogged during the interval ( s, t ) -Service curve: the minimum service received by the flow during the interval ( s, t ) t S (t) = service curve Arrival Curve D B bits WFQ implements a linear service curve

Katz, Stoica F04 42 Linear Service Curves: Example t bits t t Arrival traffic t bits tt Service curves Arrival process Service Video FTP t Video packets have to wait after ftp packets

Katz, Stoica F04 43 Non-Linear Service Curves: Example t bits t t Arrival traffic t bits tt Service curves Arrival process Service t Video FTP Video packets transmitted as soon as they arrive

Katz, Stoica F04 44 What You Need to Know  Basic concepts -Arrival & service curve -Token-bucket specification -System virtual time / finish virtual time -WFQ properties -Link sharing requirements and challenges -Bandwidth-delay coupling problem  Mechanisms: -WFQ implementation in the fluid flow & packet system  You don’t need to know -Details of WF2Q -How service curve works