Network Bandwidth Allocation (and Stability) In Three Acts Problem Statement How to allocate bandwidth to users? How to model the network? What criteria to use? Act I Modeling A Physical View C6 C1 Host 1 C2 Host 2 C7 C3 C4 C5 Host 3 Host 4 Host 5 Router : interconnect, where links meet. Host : multi-user, endpoint of communication. Link / Resource : bottleneck, each has finite capacity Cj. System Usage N 3 (t ) L 3 (N(t )) Host 1 Host 2 N1 (t ) N 2 (t ) L1 (N(t )) L 2 (N(t )) Host 3 Host 4 Host 5 Route : static path through network, supporting Ni(t) flows with Li(N(t)) allocated bandwidth. Flows / Users : transfer documents of different sizes, evenly split allocated bandwidth along route. Dynamic. Not directed. Simplification C7 C6 C1 C3 C2 C4 N 3 (t ) N1 (t ) N 2 (t ) L 3 (N(t )) L1 (N(t )) L 2 (N(t )) Extraneous elements have been removed. C5 Abstraction C1 N 3 (t ) L 3 (N(t )) C7 C6 C3 C2 C5 C4 N1 (t ) N 2 (t ) L1 (N(t )) L 2 (N(t )) Routes are just subsets of links / resources. Represented by [Aji] : whether resource j is used by route i. Capacity constraint: A L (N(t )) C i:Ni ( t ) 0 ji i j Stochastic Behavior 020 1L1 (120) 2 110 1 1 2 120 3 2L2 (120) 3L 3 (121) 220 1L1 (220) 2L2 (130) 130 121 Model N(t) as a Markov process with countable state space. Poisson user arrivals at rate i. Exponential document sizes with parameter i. Define traffic intensity ri = i / i. Act II Performance Criteria Allocation Efficiency • An allocation L is feasible if capacity constraint satisfied. • A feasible allocation L is efficient if we don’t have L for any other feasible . • Defined at a point in time, regardless of usage. 10 10 10 10 L3 5 L1 5 10 10 L2 2 10 Stability • Stable Markov chain positive recurrent. • Returns to each state with probability 1 in finite mean time. • Necessary, but not sufficient condition: A ji ri C j for all j i • How tight this is gives us an idea of utilization. • Does not uniquely specify allocation. Maximize Overall Throughput L • That is, max i:N i ( t ) 0 i • No unique allocation. • Could get unexpected results. L4 10 10 10 L1 L2 L3 Max-Min Fairness • Increase allocation for each user, unless doing so requires a corresponding decrease for a user of equal or lower bandwidth to satisfy the capacity constraints. • Uniquely determined. • Greedy algorithm. Not distributed. L3 12 12 L1 L2 Proportional Fairness • L is proportionally fair if for any other feasible allocation L* we have: L*i L i i Ni (t ) L 0 i • Same as maximizing: Ni (t ) log L i i • Interpret as utility function. • Distributed algorithms known. a-Fair Allocations 1a L a i Maximize N ( t ) if a (0, ), a 1 i i 1a G ( Λ , t ) i: N i ( t ) 0 if a 1 i N i log L i i:N i (t ) 0 Subject to A L i:Ni ( t ) 0 With i=1, a a=1 a With i = 1 / RTTi2, a=2 ji i Cj Li 0 :maximize throughput : proportional fairness :max-min fairness : TCP TCP Bias RTT timeout • Congestion window based on additive increase / multiplicative decrease mechanism. • Increase for each ACK received, once every Round Trip Time. • Timeouts based on RTT. • Bias against long RTT. Properties of a-Fair Allocations Assume Ni(t) > 0. Let L(N(t)) be a solution to the a-fair optimization. • The optimal L exists and is unique. • It’s positive: L > 0. • Scale invariance: L(rN) = L(N), for r > 0. • Continuity: L is continuous in N. • System is stable when A i ji ri C j for all j Act III Fluids & Formalities Fluid Models Decompose into non-decreasing processes: Ni (t ) Ni (0) Ei (t ) Si (Ti (t )) t Ti (t ) Li (N(s)) ds 0 Ni(0) : initial condition Ei(t) : new arrival process Ti(t) : cumulative bandwidth allocated Si(t) : service process Consider a sequence indexed by r > 0: N r (rt ) N (t ) r r 1000 9 900 8 800 7 700 6 600 E(t) 10 5 500 4 400 3 300 2 200 1 100 0 0 2 r 1 4 6 8 r 10 10 t 0 0 200 80 70 60 50 40 30 20 10 0 20 40 60 t 600 800 r 100 90 0 400 t 100 E(t) E(t) Fluid Limit : Visual 80 100 1000 Fluid Limit : Math Look at slope: r r E (t t ) E (t ) E (rt rt ) E (rt ) t rt By strong law of large numbers for renewal processes: E (rt ) as r rt Thus r E (t ) t with probability 1. Fluid Model Solution A fluid model solution is an absolutely continuous function N(t ) so that at each regular point t and each route i d dt i i L i N(t ) if N i (t ) 0 N i (t ) if N i (t ) 0 0 and for each resource j A L N(t ) A ji i:N i ( t ) 0 i i:N i ( t ) 0 ji ri C j Fluid Analysis is Easier Definition A complex function f is absolutely continuous on I=[a,b] if for every e > 0 there is a d > 0 such that n i 1 f ( b i ) f (a i ) e for any n and any disjoint collection of segments (a1,b1),…,(an,bn) in I whose lengths satisfy n b i 1 i ai d Theorem If f is AC on I, the f is differentiable a.e. on I, and x f ( x) f (a) f ' (t ) dt a Visualizing Fluid Flow 3 1 1L1 (N) 2 2 L 2 (N) 3 L 3 ( N) For Stability • If fluid system empties in finite time, then system is stable. N(t ) 0 for all t T • Show that d dt N(t ) 0 • In general, what happens as t when some of the resources are saturated? A ji ri C j i • We approach the invariant manifold, aka the set of invariant states M a N : Li (N) ri for all i where N i 0 Towards a Formal Framework • Interested in stochastic processes with samples paths in D[0, , the space of right continuous real functions having left limits. x(t ) lim x( s ) x(t ) s t t lim x(s) x(t ) s t • Well behaved. At most countably many points of discontinuity. Why we need a better metric. x1 (t ) … t … t x2 (t ) What goes wrong in Lp ? L ? Skorohod Topology Let L be the set of strictly increasing Lipschitz continuous functions mapping [0,) onto [0,), such that ' ( ) log (t ) Put r r 1 (standard bounded metric) ~ d ( x, y, , u) sup r x(t u), y( (t ) u) t 0 u ~ d ( x, y ) inf ( ) e d ( x, y, , u ) du 0 L For functions mapping to any Polish (complete, separable, metric) space. Prohorov Metric Let (S,d) be a metric space, B(S) the s-algebra of Borel subsets of S, P(S) family of Borel probability measures on S. Define r ( P, Q) inf e 0 : P( F ) Q( F e ) e for all closed F S F e x S : inf d ( x, y) e yF The resulting metric space is Polish. Fluid Limit Theorem from Gromoll & Williams Outline of Proof • Apply functional law of large numbers to load processes. • Derive dynamic equations for state and bounds. • State contained in compact set with probability 1 in limit. • State oscillations die down with probability 1 in limit. • Sequence is C-tight. • Weak limit points are fluid solutions with probability 1. Papers 1995 2000 Dai Kelly Kelly, Maulloo, Tan 2005 Bonald, Massoulié Gromoll, Williams Kelly, Williams Mo, Walrand Massoulié