Recap of Lecture 19

Post on 23-Jan-2016

28 views 0 download

Tags:

description

Recap of Lecture 19. If symptoms persist, please consult Dr Jacobson. Same caveat as the lecture …. “Everything […] is oversimplified” Read the RFCs or source code for details! (if you do, please tell us how TCP really works!) e.g. - PowerPoint PPT Presentation

transcript

Recap of Lecture 19

If symptoms persist, please consult Dr Jacobson

Same caveat as the lecture …

• “Everything […] is oversimplified”• Read the RFCs or source code for details!– (if you do, please tell us how TCP really works!)– e.g.When a TCP sender detects segment loss using the retransmission timer and the given segment has not yet been resent by way of the retransmission timer, the value of ssthresh MUST be set to no more than the value given in equation (4): ssthresh = max (FlightSize / 2, 2*SMSS)...Implementation Note: An easy mistake to make is to simply use cwnd, rather than FlightSize, which in some implementations may incidentally increase well beyond rwnd.

-- RFC 5681

Congestion Control

• What happens when two packets arrive at the same time?

• Flow control vs. congestion controlMaxWindow = min {congestion window, receiver window}

• Who takes care of congestion?

Utilization

Average packetdelay

Load

Average packet

loss

Load

Detecting Congestion

• ICMP Source Quench?– Could be lost– Adds to congestion

• Packet delays? (knee of load-delay curve)– Noisy

• Packet loss?– Fail-safe– Non-congestive loss

• SSTHRESH ← CWND / 2• CWND ← 1• Retransmit first lost packet• Slow start until CWND > SSTHRESH,

then AIMD

Fast Retransmission• 3 duplicate ACKs• CWND ← CWND/2

Worksheet

Q2Q1 Q3

CWND Flowchart

Based on EE122 section slides, 10/31/11

Start CWND += MSS

CWND += CWND = max(, MSS)

SSTHRESH = CWND = MSS

timeout3 duplicateACKs

Action when receive new

ACK

(CWND > SSTHRESH)

timeout3 duplicateACKs

Simple Fast Retransmission Additive Increase

Loss detectedby timeout

Slow Start

CWND: Advanced Fast Retransmit

Start CWND += MSS

CWND +=

SSTHRESH = CWND =

SSTHRESH = CWND = MSS

timeout

3 duplicateACKs

CWND += MSS

CWND = SSTHRESH

duplicateACK

new ACK

Action when receive new

ACK

(CWND > SSTHRESH)

timeout

Based on EE122 section slides, 10/31/11

Slow Start

Loss detectedby timeoutAdditive Increase

What would go here?

• Not all protocols TCP-friendly• High speed links– Question 1e

• Bandwidth 1/RTT∝• Bandwidth # flows∝• Cheating• What is fairness?