4 · Principles of congestion control: the three scenarios ★
Slides 3-65 → 3-76 · K&R 3.6 · HW4 P30, P39 · Sample midterm 1.1
What congestion is (3-65)
- Congestion, informally: "too many sources sending too much data too fast for the network to handle."
- Manifestation 1: long delays from queueing in router buffers.
- Manifestation 2: packet loss from buffer overflow at routers.
- Different from flow control! Congestion control = too many senders, sending too fast (for the network). Flow control = one sender too fast for one receiver.
- The slides call it a top-10 problem in networking.
Notation
- λin = rate the app hands original data to transport.
- λ'in = offered load: rate transport sends into the network, original data plus retransmissions. Always λ'in ≥ λin.
- λout = throughput: rate useful (non-duplicate) data is delivered to the receiving app.
- R = link capacity. With two connections sharing a link of rate R, each one's fair max is R/2.
Scenario 1: two senders, one router, infinite buffers (3-66)
- Setup: Hosts A and B each send at λin through one router; input and output links have capacity R; infinite buffers, so nothing is lost and no retransmissions.
- Throughput: λout = λin up to λin = R/2, then it caps at R/2 (max per-connection throughput). Sending faster than R/2 buys nothing.
- Delay: as λin approaches R/2, queueing delay grows without bound (→ ∞). Above R/2 the queue grows forever.
- Cost of congestion #1: large queueing delays as the arrival rate nears link capacity, even with no loss.
λout delay
R/2 | _______ | |
| / | /
| / | _/
| / | ___--
|__/________ λin |_________ λin
R/2 R/2 (asymptote)
Scenario 2: one router, finite buffers, retransmissions (3-67 → 3-72)
- Finite buffers: packets arriving to a full buffer are dropped, and the sender retransmits lost (timed-out) packets.
- App level: λin = λout in the long run (everything the app sends is eventually delivered). Transport level: λ'in ≥ λin because it includes retransmissions.
| Case | Assumption | Result at λ'in = R/2 |
|---|---|---|
| (a) perfect knowledge (3-68) | Sender sends only when router buffer space is free. No loss, so λ'in = λin. | λout = λin, up to R/2 |
| (b) some perfect knowledge (3-69, 3-70) | Packets can be dropped at a full buffer. Sender knows exactly when a packet was dropped and resends only those. | λout = R/3: of 0.5R sent, 0.333R is original data and 0.167R is retransmissions |
| (c) realistic: un-needed duplicates (3-71, 3-72) | Sender can time out prematurely and send a second copy; both copies get delivered. | λout = R/4 if each packet is forwarded twice on average |
- Cost #2: the sender does more work (retransmissions) for a given receiver throughput. Some of the R/2 is "wasted" on needed retransmissions.
- Cost #3: unneeded retransmissions: the link carries multiple copies of a packet, decreasing the maximum achievable throughput.
Scenario 3: four senders, multihop paths (3-73, 3-74)
- Setup: four senders, multi-hop paths (each flow crosses two routers), finite buffers, timeout/retransmit. Every link has capacity R.
- Each router is shared by a one-hop-in flow (just entered) and a two-hop flow (already crossed an upstream router).
- Small λin: few drops, λout ≈ λin.
- Large λ'in: as the red flow's λ'in increases, it fills the upper router's queue, and all arriving blue packets there are dropped: blue throughput → 0. In the limit, end-to-end throughput across the network goes to zero (the curve rises, peaks near R/2, then falls).
- Cost #4: when a packet is dropped, any upstream transmission capacity and buffering used for that packet was wasted. The first router forwarded it for nothing.
λout
R/2 | _
| / \
| / \
| / \___
|/____________\__ λ'in
R/2
Two approaches to congestion control (3-75, 3-76)
| End-to-end | Network-assisted | |
|---|---|---|
| Feedback | No explicit feedback from the network | Routers provide direct feedback to hosts whose flows pass through the congested router |
| How congestion is detected | Inferred from observed loss and delay | Router may indicate a congestion level or explicitly set the sending rate |
| Examples | TCP (the classic approach) | TCP ECN, ATM (ABR), DECbit |
- Network-assisted feedback comes either as a direct choke packet from router to sender, or by the router marking a packet heading to the receiver, which then tells the sender (costs a full RTT).
How to solve: scenario 2 throughput numbers
- Find the per-connection cap: two hosts share R, so R/2 leaves the router per connection.
- Decide what fraction f of the packets leaving the router are useful originals.
λout = f × (rate leaving the router for this connection).- Case b at λ'in = R/2: f = 2/3 → λout = (2/3)(R/2) = R/3. Case c, each packet forwarded twice: f = 1/2 → λout = (1/2)(R/2) = R/4.
Worked: HW4 P39
Q (HW4 P39): Use Scenario 2's performance curves (K&R Fig. 3.46, finite buffers). Answer each part and explain.
- (b) Consider Figure 3.46(b). If λ'in increases beyond R/2, can λout increase beyond R/3? Explain.
- (c) Now consider Figure 3.46(c). If λ'in increases beyond R/2, can λout increase beyond R/4, under the assumption that a packet is forwarded twice on average from the router to the receiver? Explain.
(b) At λ'in = R/2: 1 of every 3 packets leaving the queue is a retransmission
useful = (2/3)(R/2) = R/3
λ'in > R/2 → total arrivals exceed queue capacity → more loss
→ an even larger fraction (≥ 1/3) of departures are retransmissions
departures per session are still capped at R/2
⇒ λout cannot exceed R/3. Answer: NO.
(c) Each packet forwarded twice on average → half of departures are duplicates
useful = (1/2)(R/2) = R/4
raising λ'in past R/2 does not raise the R/2 departure cap,
and only adds more loss/duplicates
⇒ λout cannot exceed R/4. Answer: NO.
Worked: HW4 P30
Q (HW4 P30): Consider the network in Scenario 2 of Section 3.6.1 (one router with finite buffers, retransmissions). Suppose both sending hosts A and B have some fixed timeout values.
- (a) Argue that increasing the size of the router's finite buffer might possibly decrease the throughput (λout).
- (b) Now suppose both hosts dynamically adjust their timeout values (like TCP does) based on the buffering delay at the router. Would increasing the buffer size help increase the throughput? Why?
(a) bigger buffer → longer queues → longer queueing delay → RTT grows
fixed timeout no longer covers the RTT → senders time out PREMATURELY
→ packets retransmitted even though they were not lost (case c)
→ duplicate copies use link capacity → λout can DROP.
(b) adaptive timeout tracks the queueing delay → no premature timeouts
bigger buffer → fewer drops → fewer retransmissions → throughput UP.
Catch: queueing delay can become very large, as in Scenario 1.
Worked: sample midterm 1.1
Q (Sample midterm 1.1): Suppose all senders in the network have low processing power and all receivers have high processing power. Will network congestion occur? Why?
- Yes, it can. Congestion happens in the network, at router buffers and links, not at the receiver.
- Many slow senders can still together send more than a shared bottleneck link's capacity R. The router queue grows, delay rises, and the buffer overflows.
- Fast receivers only remove the flow control problem (receiver buffer overflow). That's a different problem.
Traps
• Congestion is a network problem (routers); flow control is a receiver problem. Fast receivers don't prevent congestion.
• Scenario 1 has no loss; its cost is delay → ∞, not dropped packets.
• λ'in includes retransmissions; λin and λout don't. Don't mix them up.
• R/3 is the useful throughput when the offered load λ'in is R/2. The other R/6 is retransmissions.
• R/4 needs the assumption "each packet forwarded twice on average" (half are duplicates).
• Raising λ'in past R/2 never raises λout past R/3 or R/4; it only adds loss.
• In Scenario 3 throughput doesn't just plateau; it falls toward 0.
• A bigger buffer with fixed timeouts can hurt throughput (P30a).
• TCP is end-to-end (loss/delay inference); ECN is the network-assisted add-on.
• Congestion is a network problem (routers); flow control is a receiver problem. Fast receivers don't prevent congestion.
• Scenario 1 has no loss; its cost is delay → ∞, not dropped packets.
• λ'in includes retransmissions; λin and λout don't. Don't mix them up.
• R/3 is the useful throughput when the offered load λ'in is R/2. The other R/6 is retransmissions.
• R/4 needs the assumption "each packet forwarded twice on average" (half are duplicates).
• Raising λ'in past R/2 never raises λout past R/3 or R/4; it only adds loss.
• In Scenario 3 throughput doesn't just plateau; it falls toward 0.
• A bigger buffer with fixed timeouts can hurt throughput (P30a).
• TCP is end-to-end (loss/delay inference); ECN is the network-assisted add-on.
Quick check
1. Define congestion in one line.
Too many sources sending too much data too fast for the network to handle.2. What are the two manifestations of congestion, and where does each come from?
Long delays (queueing in router buffers) and lost packets (buffer overflow at routers).3. All senders have low processing power and all receivers have high processing power. Will congestion occur? Why? (sample 1.1)
Yes, it can. Congestion happens at router buffers / shared links inside the network. Many slow senders can together exceed a bottleneck link's capacity. Fast receivers only rule out receiver overflow, which is flow control, not congestion.4. Give the scenario 2 throughputs R/2, R/3, R/4 and why each.
R/2 (case a): two connections share R and the sender only sends when there is buffer space, so no loss and λout = λin up to R/2.R/3 (case b): offered load λ'in = R/2, but losses force retransmissions; 1 of every 3 packets leaving is a retransmission, so useful = (2/3)(R/2) = R/3.
R/4 (case c): premature timeouts send duplicates; if each packet is forwarded twice on average, half are useless, so useful = (1/2)(R/2) = R/4.
5. Scenario 1: what happens to throughput and delay as λin → R/2?
Throughput rises to λout = R/2 and caps there. Queueing delay goes to infinity. No packets are lost (infinite buffers).6. New numbers: R = 12 Mbps, scenario 2 case b, λ'in = R/2. What are λout and the retransmission rate per host?
λ'in = 12/2 = 6 Mbps λout = (2/3)(6) = 4 Mbps (= R/3) retx = 6 − 4 = 2 Mbps (1/3 of λ'in)
7. Variant of case c: each packet is forwarded three times on average and the per-connection departure rate is R/2. Max λout? With R = 12 Mbps?
Only 1 of every 3 copies is useful:λout = (1/3)(R/2) = R/6. With R = 12 Mbps: 2 Mbps.8. A host offers λ'in = 5 Mbps and 20% of what it sends are retransmissions. What is λout?
λout = (1 − 0.20) × 5 = 0.8 × 5 = 4 Mbps
9. Scenario 3: what is the new cost of congestion?
When a packet is dropped downstream, all upstream transmission capacity and buffering used for it was wasted. As λ'in grows, throughput goes to zero.10. HW4 P30a: with fixed timeouts, how can a bigger router buffer lower throughput?
Bigger buffer → longer queueing delay → RTT exceeds the fixed timeout → premature timeouts → unneeded duplicates eat link capacity → λout drops.11. HW4 P30b: with adaptive timeouts, does a bigger buffer help? Any catch?
Yes, fewer drops means fewer retransmissions, so throughput rises. The catch: queueing delay can become very large, as in Scenario 1.12. End-to-end vs network-assisted congestion control: which does TCP use, and name three network-assisted examples.
TCP uses end-to-end: no network feedback, congestion inferred from loss and delay. Network-assisted: TCP ECN, ATM (ABR), DECbit, where routers give explicit feedback or set the rate.13. In HW4 P39(b), can λout exceed R/3 if λ'in goes above R/2?
No. Departures per session are capped at R/2, and pushing λ'in higher causes more loss, so at least 1/3 of departures are retransmissions. Useful throughput stays ≤ R/3.← prev · all topics · next →