Announcements Homework #3 solutions now available Quality of Service (QoS) Reminder, phase of Project #3 due this Thurs evening with no slip days EE : Intro to Communication Networks Fall 006 (MW -5:30 in Donner 55) Vern Paxson TAs: Dilip Antony Joseph and Sukun Kim http://inst.eecs.berkeley.edu/~ee/ Materials with thanks to Jennifer Rexford, Ion Stoica, and colleagues at Princeton and UC Berkeley Goals of Today s Lecture How can we get some sort of reliable performance from the network? If we need it QoS mechanisms from fine-grained to large-scale: Queuing algorithms beyond FIFO (isolation, fairness) End-to-end network reservations (Integrated Services) First Class vs. Coach (Differentiated Services) Why none of this actually works At least, not end-to-end Scheduling Decide when and what packet to send on output link Classifier partitions incoming traffic into flows each with their own FIFO queue Classifier flow flow flow n Buffer management Scheduler The struggle over network neutrality 3 Link Scheduling: FIFO What if scheduler uses one first-in first-out queue? Simple to implement But, restrictive in providing guarantees Example: two kinds of traffic Video conferencing needs high bandwidth and low delay E.g., Mbps and 00 msec delay E-mail transfers not very sensitive to delay Cannot admit much e-mail traffic Since it will interfere with the video conference traffic Link Scheduling: Strict Priority Strict priority Multiple levels of priority Always transmit high-priority traffic, when present.. and force the lower priority traffic to wait Isolation for the high-priority traffic Almost like it has a dedicated link Except for the (small) delay for packet transmission High-priority packet arrives during transmission of low-priority Router completes sending the low-priority traffic first 5 6
Link Scheduling: Weighted Fairness Limitations of strict priority Lower priority queues may starve for long periods even if the high-priority traffic can afford to wait Traffic still competes inside each priority queue Weighted fair scheduling Assign each queue a fraction of the link bandwidth Rotate across the queues on a small scale Send extra traffic from one queue if others are idle Max-Min Fairness Denote C link capacity N number of flows r i arrival rate Max-min fair rate computation:. compute C/N. if there are flows i such that r i C/N, update C and N C = C " $ r i ; N = N " k (for k such flows) i s.t r i #C / N 3. if no, f = C/N; terminate. go to Flows receive at most the fair rate, i.e., min(f, r i ) 50% red, 5% blue, 5% green 7 8 Example C = 0; r = 8, r = 6, r 3 = ; N = 3 C/3 = 3.33 Can service all of r 3 Remove r 3 from the accounting: C = C r 3 = 8; N = C/ = Can t service all of r or r So hold them to the remaining fair share: f = Fair Queuing (FQ) [DKS 89] Conceptually, computes when each bit in the queue should be transmitted to attain max-min fairness (a fluid flow system approach) Then serve packets in the order of the transmission of their last bits 8 6 0 f = : min(8, ) = min(6, ) = min(, ) = 9 0 Example Flow (arrival traffic) Flow (arrival traffic) Service in fluid flow system Packet system 3 3 5 3 3 3 3 5 6 5 6 5 5 5 6 Fair Queuing (FQ) [DKS 89] Conceptually, computes when each bit in the queue should be transmitted to attain max-min fairness (a fluid flow system approach) Then serve packets in the order of the transmission of their last bits Provides isolation: misbehaving flow can t impair others Doesn t solve congestion: still need to deal with individual queues filling up Generalized to Weighted Fair Queuing (WFQ)
Reserving Resources End-to-End Source sends a reservation message E.g., this flow needs 5 Mbps Each router along the path Keeps track of the reserved resources E.g., the link has 6 Mbps left Checks if enough resources remain E.g., 6 Mbps > 5 Mbps, so circuit can be accepted Creates state for flow and reserves resources E.g., now only Mbps is available 3 Specifying Bursty Traffic Option #: Specify the maximum bit rate Maximum bit rate may be much higher average Reserving for the worst case is wasteful Option #: Specify the average bit rate Average bit rate is not sufficient Network will not be able to carry all of the packets Reserving for average case leads to bad performance Option #3: Specify the burstiness of the traffic Specify both the average rate and the burst size Allows the sender to transmit bursty traffic and the network to reserve the necessary resources Characterizing Burstiness: Token Bucket Parameters r average rate, i.e., rate at which tokens fill the bucket b bucket depth (limits size of burst) R maximum link capacity or peak rate A bit is transmitted only when token is available r bps b bits bits b R/(R-r) slope R Maximum # of bits sent slope r Traffic Enforcement: Example r = 00 Kbps; b = 3 Kb; R = 500 Kbps 3Kb T = 0 : Kb packet arrives.kb (a) (c) 3Kb.Kb (b) T = ms : packet transmitted b = 3Kb Kb + ms*00kbps =.Kb (d) (e) 0.6Kb regulator R bps 5 T = ms : 3Kb packet arrives T = 0ms : packet needs to wait until enough tokens are in the bucket T = 6ms : packet transmitted 6 Source Traffic Characterization: Arrival Curve Arrival curve maximum amount of bits transmitted during an interval of Δt Use token bucket to bound arrival curve Arrival Curve: Example Arrival curve maximum amount of bits transmitted during an interval of Δt Use token bucket to bound arrival curve bits (R=,b=,r=) Arrival curve bps bits Arrival curve bps 3 Δt 0 3 5 3 5 Δt 7 8 3
QoS Guarantees: Per-hop Reservation End-host: specify arrival rate characterized by token-bucket with parameters (b,r,r) the maximum admissible delay D, no losses Router: allocate bandwidth r a, buffer space B a such that no packet is dropped no packet experiences a delay larger than D bits b*r/(r-r) R slope r a slope r B a D Arrival curve 9 Ensuring the Source Behaves Guarantees depend on the source behaving Extra traffic might overload one or more links Leading to congestion, and resulting delay and loss Solution: need to enforce the traffic specification Solution #: policing Drop all data in excess of the traffic specification Solution #: shaping Delay the data until it obeys the traffic specification Solution #3: marking Mark all data in excess of the traffic specification and give these packets lower priority in the network 0 Integrated Services: Required Elements Reservation Protocol How service request gets from host to network Admission control algorithm How network decides if it can accept flow Packet scheduling algorithms How routers deliver service Architecture for solution: IntServ Provides service guarantees at a per-flow Control Plane vs. Data Plane Control plane: How information gets to routers Data plane: What routers do with that information when processing data packets Data Control granularity Control Plane: Resource Reservation Control Plane: Resource Reservation sends specification of traffic profile 3
Control Plane: Resource Reservation Control Plane: Resource Reservation Path established (or perhaps admission control denies path) The receiver signals reservation request 5 6 Control Plane: Admission Control Control Plane: Admission Control Per-flow state (soft state) Per-flow state on all routers in path 7 8 Data Plane Data Plane Per-flow classification on each router Per-flow classification on each router 9 30 5
Data Plane Per-flow scheduling on each router 5 Minute Break Questions Before We Proceed? 3 3 Admission Control Problems with IntServ Parameter-based: worst case analysis Scalability: per-flow state & classification Guaranteed service Lower utilization Measurement-based: measure current traffic Controlled load service Higher utilization Aggregation/encapsulation techniques can help Can overprovision big links, per-flow ok on small links Scalability can be fixed - but no second chance Economic arrangements: Need sophisticated settlements between ISPs Contemporary settlements are primitive Unidirectional, or barter User charging mechanisms: need QoS pricing Remember that best-effort service co-exists On a fine-grained basis No need for IntServ traffic to achieve high utilization 33 Differentiated Services (DiffServ) 3 Diffserv Architecture Give some traffic better treatment than other Ingress routers - entrance to a DiffServ domain Police or shape traffic Set Differentiated Service Code Point (DSCP) in IP header Application requirements: interactive vs. bulk transfer Economic arrangements: first-class versus coach Core routers What kind of better service could you give? Implement Per Hop Behavior (PHB) for each DSCP Process packets based on DSCP Fewer drops Lower delay Lower delay variation (jitter) DS- DS- How to know which packets get better service? Ingress Bits in packet header Egress Ingress Egress Deals with traffic in aggregate Provides weaker services But much more scalable Edge router 35 Core router 36 6
Differentiated Service (DS) Field Comparison to Best-Effort & Intserv 0 5 6 7 DS Field ECN 0 8 6 9 3 Version HLen TOS Length Identification Flags Fragment offset TTL Protocol Header checksum Source address Destination address Data IP header DS field encodes Per-Hop Behavior (PHB) E.g., Expedited Forwarding (all packets receive minimal delay & loss) E.g., Assured Forwarding (packets marked with low/high drop probabilities) 37 Service Service scope Complexity Scalability Best-Effort Connectivity No isolation No guarantees End-to-end No setup Highly scalable (nodes maintain only routing state) Diffserv Per aggregate isolation Per aggregate guarantee Domain Long term setup Scalable (edge routers maintain per aggregate state; core routers per class state) Intserv Per flow isolation Per flow guarantee End-to-end Per flow steup Not scalable (each router maintains per flow state) 38 Discussion: Limited QoS Deployment End-to-end QoS across multiple providers/domains is not available today Issue #: complexity of payment Requires payment system among multiple parties And agreement on what constitutes service Diffserv tries to structure this as series of bilateral agreements but lessens likelihood of end-to-end service Architecture includes notion of Bandwidth Broker for end-toend provisioning Solid design has proved elusive Need infrastructure for metering/billing end user 39 Limited QoS Deployment, con t Issue #: prevalence of overprovisioning Within a large ISP, links tend to have plenty of headroom Inter-ISP links are not over provisioned, however Is overprovisioning enough? If so, is this only because access links are slow? What about Korea, Japan, and other countries with fast access links? Disconnect: ISPs overprovision, users get bad service Key difference: intra-isp vs. general end-to-end 0 Exploiting Lack of End-to-End QoS Network Neutrality Suppose an ISP offers their own Internet service E.g., Portal (ala Yahoo), search engine (ala Google) Then it s in their interest that service to Yahoo or Google is inferior So customers prefer to use their value-added services ISP can recognize traffic to competitor and demote it charge competitor if they want well-provision paths just not put effort/$ into high-capacity interconnects w/ other ISPs; congestion provides traffic demotion directly Works particularly well for large providers w/ lots Network neutrality = notion that ISPs supply non-discriminated IP connectivity Opposite counterpoint: a Walled Garden Provider only allows you to access their (often value-added) services E.g., AOL s captive Web portal/email/im Highly contentious; potential legal fray E.g., ISPs blocking Voice-over-IP (VOIP) As does China, Panama, Costa Rica E.g., ISPs blocking 5/tcp (SMTP) to curb spammers of valuable content 7
Network Neutrality, con t Is Internet access something that ISPs provide as common carriers? Transporting goods as service to common public Or: will free market forces serve to shape ISP favoritism efficiently? Is there a danger of monopolies emerging? Many QoS-sensitive apps can be written in an adaptive style to deal with uncertainties But what about stricter apps? Summary Basic mechanism for achieving better-than-best-effort performance: scheduling Multiple queues allow priority service Fair queuing provides isolation between flows But: still need end-to-end mechanisms Reservations & admission control Descriptions of bursty traffic: token buckets IntServ provides per-flow performance guarantees But lacks scalability DiffServ provides per-aggregate tiers of relative perf. Scalable, but not as powerful Neither is generally available end-to-end today ISPs manipulating what services receive what performance raises issues of network neutrality Standard example: telesurgery 3 8