TCP EE122 Discussion 10/18/13
TCP Sequence Numbers Initial sequence number for the connection is not zero Sequence number refers to the first byte in the TCP packet payload
Example (from class) Packet arrives: – Seq: 2323 – Ack: 4001 – W=3000 – [no payload] Appropriate response? Seq: 4001, payload: 4001-8000 Seq: 2001, payload: 2001-5000 Seq: 4001, payload: 4001-5000 Seq: 5001, payload: 5001-6001 Seq: 8001, payload: 8001-9000
Congestion Control [1] • Avoid overwhelming the network • cwnd – congestion window • SSTHRESH –threshold until which exponential slow-start happens • TCP is either in slow-start mode or AIMD mode
Congestion Control [2] • TCP is either in slow-start mode or AIMD mode • Slow-start: for every ACK, increase cwnd by MSS • “AI”: for every window of packets being ACK-ed, increase cwnd by MSS
‘Vanilla’ TCP Exponential slow-start till SSTHRESH Set timer, which expires when packets are lost At each new data ACK the timeout is RESET On time-out, set SSTHRESH to (cwnd/2), and cwnd itself to 1 – Timeout = receiving nothing for an entire RTO Usually a disaster!