Fair Queueing. Design space Buffer management: –RED, Drop-Tail, etc. Scheduling: which flow to service at a given time –FIFO –Fair Queueing.

Slides:



Advertisements
Similar presentations
Congestion Control and Fairness Models Nick Feamster CS 4251 Computer Networking II Spring 2008.
Advertisements

Computer Networking Lecture 20 – Queue Management and QoS.
1 CNPA B Nasser S. Abouzakhar Queuing Disciplines Week 8 – Lecture 2 16 th November, 2009.
CSIT560 Internet Infrastructure: Switches and Routers Active Queue Management Presented By: Gary Po, Henry Hui and Kenny Chong.
Congestion Control Reasons: - too many packets in the network and not enough buffer space S = rate at which packets are generated R = rate at which receivers.
CS 268: Lecture 8 Router Support for Congestion Control Ion Stoica Computer Science Division Department of Electrical Engineering and Computer Sciences.
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.
Scheduling CS 215 W Keshav Chpt 9 Problem: given N packet streams contending for the same channel, how to schedule pkt transmissions?
CS 268: Lecture 15/16 (Packet Scheduling) Ion Stoica April 8/10, 2002.
Generalized Processing Sharing (GPS) Is work conserving Is a fluid model Service Guarantee –GPS discipline can provide an end-to-end bounded- delay service.
Analysis and Simulation of a Fair Queuing Algorithm
CS 268: Lecture 8 (Router Support for Congestion Control) Ion Stoica February 19, 2002.
1 Core-Stateless Fair Queueing: Achieving Approximately Fair Bandwidth Allocations in High Speed Networks Ion Stoica,Scott Shenker, and Hui Zhang SIGCOMM’99,
ACN: Congestion Control1 Congestion Control and Resource Allocation.
Computer Networking Lecture 17 – Queue Management As usual: Thanks to Srini Seshan and Dave Anderson.
Lecture 5: Congestion Control l Challenge: how do we efficiently share network resources among billions of hosts? n Last time: TCP n This time: Alternative.
Core Stateless Fair Queueing Stoica, Shanker and Zhang - SIGCOMM 98 Rigorous fair Queueing requires per flow state: too costly in high speed core routers.
UCB Improvements in Core-Stateless Fair Queueing (CSFQ) Ling Huang U.C. Berkeley cml.me.berkeley.edu/~hlion.
Core Stateless Fair Queueing Stoica, Shanker and Zhang - SIGCOMM 98 Fair Queueing requires per flow state: too costly in high speed core routers Yet, some.
Packet Scheduling From Ion Stoica. 2 Packet Scheduling  Decide when and what packet to send on output link -Usually implemented at output interface 1.
CS640: Introduction to Computer Networks Aditya Akella Lecture 20 - Queuing and Basics of QoS.
1 Queue Management Hamed Khanmirza Principles of Networking University of Tehran.
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.
ACN: CSFQ1 CSFQ Core-Stateless Fair Queueing Presented by Nagaraj Shirali Choong-Soo Lee ACN: CSFQ1.
CS 268: Computer Networking L-5 Router Queue Management.
Advance Computer Networking L-6 TCP & Routers Acknowledgments: Lecture slides are from the graduate level Computer Networks course thought by Srinivasan.
ACN: RED paper1 Random Early Detection Gateways for Congestion Avoidance Sally Floyd and Van Jacobson, IEEE Transactions on Networking, Vol.1, No. 4, (Aug.
Fair Queueing. 2 First-Come-First Served (FIFO) Packets are transmitted in the order of their arrival Advantage: –Very simple to implement Disadvantage:
Presented by: Peng Wang EE Department University of Delaware A Probabilistic Approach for Achieving Fair Bandwidth Allocation in CSFQ.
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.
Queueing and Active Queue Management Aditya Akella 02/26/2007.
9.7 Other Congestion Related Issues Outline Queuing Discipline Avoiding Congestion.
Packet Scheduling and Buffer Management Switches S.Keshav: “ An Engineering Approach to Networking”
CS640: Introduction to Computer Networks Aditya Akella Lecture 20 - Queuing and Basics of QoS.
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.
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
Spring Computer Networks1 Congestion Control Sections 6.1 – 6.4 Outline Preliminaries Queuing Discipline Reacting to Congestion Avoiding Congestion.
15-744: Computer Networking L-5 TCP & Routers. 2 Fair Queuing Core-stateless Fair queuing Assigned reading [DKS90] Analysis and Simulation of a Fair Queueing.
15-744: Computer Networking L-5 TCP & Routers. 2 Fair Queuing Core-stateless Fair queuing Assigned reading [DKS90] Analysis and Simulation of a Fair Queueing.
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.
1 Lecture 15 Internet resource allocation and QoS Resource Reservation Protocol Integrated Services Differentiated Services.
CS244 Packet Scheduling (Generalized Processor Sharing) Some slides created by: Ion Stoica and Mohammad Alizadeh
Corelite Architecture: Achieving Rated Weight Fairness
QoS & Queuing Theory CS352.
CS 268: Computer Networking
Chapter 6 Queuing Disciplines
Congestion Control and Resource Allocation
EE 122: Router Support for Congestion Control: RED and Fair Queueing
TCP, XCP and Fair Queueing
Queuing and Queue Management
15-744: Computer Networking
Fair Queueing.
Advance Computer Networking
Computer Science Division
Advance Computer Networking
Network Simulation NET441
COMP/ELEC 429 Introduction to Computer Networks
15-744: Computer Networking
Congestion Control Reasons:
15-744: Computer Networking
Congestion Control and Resource Allocation
EECS 122: Introduction to Computer Networks Packet Scheduling and QoS
Fair Queueing.
کنترل جریان امیدرضا معروضی.
Presentation transcript:

Fair Queueing

Design space Buffer management: –RED, Drop-Tail, etc. Scheduling: which flow to service at a given time –FIFO –Fair Queueing

Scheduling Work-conserving: –Link is never idle if there are packets to send –Examples: FIFO, Fair Queueing Non-work conserving –… –Examples: TDMA

Fairness Goals Allocate resources fairly Isolate ill-behaved users –Router does not send explicit feedback to source –Still needs e2e congestion control Still achieve statistical muxing –One flow can fill entire pipe if no contenders –Work conserving scheduler never idles link if it has a packet

A Caveat: Still need e2e Congestion collapse can still happen if you have fair queueing (router-assisted sharing) 10 Mbps 1.5 Mbps 128 Kbps TCP Non-cong. Ctld UDP Example from Floyd and Fall, 1999

What does fairness divide between? At what granularity? –Flows, connections, domains? What if users have different RTTs/links/etc. –Should it share a link fairly or be TCP fair? Basically a tough question to answer – typically design mechanisms instead of policy –User = arbitrary granularity –Paper has a nice argument for (src, dst) pairs

Max-min Fairness (reminder) Allocate user with small demand what it wants, evenly divide unused resources to big users Formally: Resources allocated in terms of increasing demand No source gets resource share larger than its demand Sources with unsatisfied demands get equal share of resource

Max-min Fairness Example (reminder) Assume sources 1..n, with resource demands X1..Xn in ascending order Assume channel capacity C. –Give C/n to X1; if this is more than X1 wants, divide excess (C/n - X1) to other sources: each gets C/n + (C/n - X1)/(n-1) –If this is larger than what X2 wants, repeat process

Implementing Max-min Fairness Important point: –Converge to some α, s.t. Flows with offered load ri < α get ri Flows with load > α get α – i=1 to n min(ri, α) = C (capacity) Generalized processor sharing –Fluid fairness –Bitwise round robin among all queues Why not simple round robin? –Variable packet length can get more service by sending bigger packets –Unfair instantaneous service rate What if arrive just before/after packet departs?

Bit-by-bit RR Multiple flows: clock ticks when a bit from all active flows is transmitted a round –µ = #bits/sec router can send, N = # active flows –dR/dt (the rate at which the round #increases) is variable = µ / N –Why count this way? # of rounds to send a packet is independent of number of active flows. Useful way of viewing things…

Bit-by-bit round robin Packet arrives in queue Q: –Its the ith packet in the queue –Its p_i^q bits long –When does it start being transmitted? If q empty, immediately: R(t) Else, just after prior pkt finishes: F_{i-1}^q S_i^q = max( R(t), F_{i-1}^q ) –When does it complete? S_i^q + p_i^q (p_i^q rounds later…) –Can compute the finish round of every packet in the queue. (Even at the point when the packet is enqueued). Note that we dont know the actual finish time, just the round #.

Packet-based Fair Queueing Simple: Send the packet with the smallest finishing round #. Approximates bit-by-bit RR –Why isnt it exact? Preemption!

FQ Illustration Flow 1 Flow 2 Flow n I/P O/P Variation: Weighted Fair Queuing (WFQ)

Bit-by-bit RR Example F=10 Flow 1 (arriving) Flow 2 transmitting Output F=2 F=5 F=8 Flow 1Flow 2 Output F=10 Cannot preempt packet currently being transmitted

Delay Allocation Reduce delay for flows using less than fair share –Advance finish times for sources whose queues drain temporarily Schedule based on B i instead of F i –F i = P i + max (F i-1, A i ) B i = P i + max (F i-1, A i - ) –If A i < F i-1, conversation is active and has no effect –If A i > F i-1, conversation is inactive and determines how much history to take into account Infrequent senders do better when history is used

Fair Queuing Tradeoffs FQ can control congestion by monitoring flows –Non-adaptive flows can still be a problem – why? Complex state –Must keep queue per flow Hard in routers with many flows (e.g., backbone routers) Flow aggregation is a possibility (e.g. do fairness per domain) Complex computation –Classification into flows may be hard –Must keep queues sorted by finish times –dR/dt changes whenever the flow count changes

Core-Stateless Fair Queuing Key problem with FQ is core routers –Must maintain state for many (50-100k!) flows –Must update state at Gbps line speeds CSFQ (Core-Stateless FQ) objectives –Edge routers should do complex tasks since they have fewer flows (1000s) –Core routers can do simple tasks No per-flow state/processing this means that core routers can only decide on dropping packets not on order of processing Can only provide max-min bandwidth fairness not delay allocation

Core-Stateless Fair Queuing Edge routers keep state about flows and do computation when packet arrives DPS (Dynamic Packet State) –Edge routers label packets with the result of state lookup and computation –Note: Generalizes beyond CSFQ! Core routers use DPS and local measurements to control processing of packets

Key ideas DPS: Edges estimate arrival rate for each flow (per-flow state) Core routers use –Estimated arrival rates from edge –Internal measure of fair-share –To generate a drop probability. Labels changed on outbound flow with new post-drop arrival rate. Estimation for fair-share value converges rapidly

Edge Router Behavior Monitor each flow i to measure its arrival rate (r i ) –EWMA of rate t_i^k, l_i^k = arrival time, length of kth packet in flow i –Non-constant EWMA constant T_i^k = interarrival (time since last pkt) (t_i^k – t_{i-1}^k) Constant: e -T/K where T, K = constant Ri new = (1 – const)* length/interarrival + const*(ri old) Helps adapt to different packet sizes and arrival patterns –Intuition: Trusts the old values less as the time interval increases (negative T) Rate is attached to each packet

Core Router Behavior Drop probability for packet = max(1- /r, 0) Track aggregate input A Track accepted rate F( ) Estimate fair share rate –Solve F( ) = C; but this is hard: –Note: Increasing does not increase load (F) by N * Δ (why?) –F( ) = i min(r i, ) what does this look like?

F vs. Alpha New alpha C [linked capacity] r1r2r3old alpha alpha F

Estimating Fair Share Need F( ) = capacity = C –Cant keep map of F( ) values would require per flow state –If were overutilized: –Since F( ) is concave, piecewise-linear F(0) = 0 and F( ) = current accepted rate = F c F( ) = F c / F( new ) = C new = old * C/F c –If underutilized: = max_i (ri) (No drops at all) What if a mistake was made? –Forced into dropping packets due to buffer capacity –When queue overflows is decreased slightly –Note that this is an increase/decrease rule in disguise.

Other Issues Punishing fire-hoses – why? –Easy to keep track of in a FQ scheme What are the real edges in such a scheme? –Must trust edges to mark traffic accurately –Could do some statistical sampling to see if edge was marking accurately