SlideShare a Scribd company logo
1 of 34
TTCCPP 
CCoonnggeessttiioonn CCoonnttrrooll 
Lecture material taken from 
“Computer Networks A Systems Approach”, 
Fourth Edition,Peterson and Davie, 
Morgan Kaufmann, 2007. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 11
TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 
• Essential strategy :: The TCP host sends 
packets into the network without a reservation 
and then the host reacts to observable events. 
• Originally TCP assumed FIFO queuing. 
• Basic idea :: each source determines how 
much capacity is available to a given flow in the 
network. 
• ACKs are used to ‘pace’ the transmission of 
packets such that TCP is “self-clocking”. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 22
AAIIMMDD 
((AAddddiittiivvee IInnccrreeaassee // MMuullttiipplliiccaattiivvee 
DDeeccrreeaassee)) 
• CongestionWindow (cwnd) is a variable held by 
the TCP source for each connection. 
MaxWindow :: min (CongestionWindow , AdvertisedWindow) 
EffectiveWindow = MaxWindow – (LastByteSent -LastByteAcked) 
• cwnd is set based on the perceived level of 
congestion. The Host receives implicit (packet 
drop) or explicit (packet mark) indications of 
internal congestion. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 33
AAddddiittiivvee IInnccrreeaassee ((AAII)) 
• Additive Increase is a reaction to perceived available 
capacity (referred to as congestion avoidance stage). 
• Frequently in the literature, additive increase is defined 
by parameter α (where the default is α = 1). 
• Linear Increase :: For each “cwnd’s worth” of packets 
sent, increase cwnd by 1 packet. 
• In practice, cwnd is incremented fractionally for each 
arriving ACK. 
increment = MSS x (MSS /cwnd) 
cwnd = cwnd + increment 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 44
Source Destination 
Add one packet 
each RTT 
FFiigguurree 66..88 AAddddiittiivvee IInnccrreeaassee 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 55
MMuullttiipplliiccaattiivvee DDeeccrreeaassee ((MMDD)) 
* Key assumption :: a dropped packet and resultant 
timeout are due to congestion at a router. 
• Frequently in the literature, multiplicative decrease 
is defined by parameter β (where the default is β = 
0.5) 
Multiplicate Decrease:: TCP reacts to a timeout by 
halving cwnd. 
• Although defined in bytes, the literature often 
discusses cwnd in terms of packets (or more 
formally in MSS == Maximum Segment Size). 
• cwnd is not allowed below the size of a single 
packet. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 66
AAIIMMDD 
((AAddddiittiivvee IInnccrreeaassee // MMuullttiipplliiccaattiivvee 
DDeeccrreeaassee)) 
• It has been shown that AIMD is a necessary 
condition for TCP congestion control to be stable. 
• Because the simple CC mechanism involves 
timeouts that cause retransmissions, it is important 
that hosts have an accurate timeout mechanism. 
• Timeouts set as a function of average RTT and 
standard deviation of RTT. 
• However, TCP hosts only sample round-trip time 
once per RTT using coarse-grained clock. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 77
FFiigguurree 66..99 TTyyppiiccaall TTCCPP 
SSaawwttooootthh PPaatttteerrnn 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 88 
60 
50 
40 
20 
1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 
Time (seconds) 
70 
30 
10 
10.0
SSllooww SSttaarrtt 
• Linear additive increase takes too long to 
ramp up a new TCP connection from cold 
start. 
• Beginning with TCP Tahoe, the slow start 
mechanism was added to provide an initial 
exponential increase in the size of cwnd. 
Remember mechanism by: slow start 
prevents a slow start. Moreover, slow start 
is slower than sending a full advertised 
window’s worth of packets all at once. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 99
SSllooww SSttaarrtt 
• The source starts with cwnd = 1. 
• Every time an ACK arrives, cwnd is 
incremented. 
cwnd is effectively doubled per RTT “epoch”. 
• Two slow start situations: 
 At the very beginning of a connection {cold start}. 
 When the connection goes dead waiting for a 
timeout to occur (i.e, the advertized window goes 
to zero!) 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1100
Source Destination 
Slow Start 
Add one packet 
per ACK 
FFiigguurree 66..1100 SSllooww SSttaarrtt 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1111
SSllooww SSttaarrtt 
• However, in the second case the 
source has more information. The 
current value of cwnd can be saved as 
a congestion threshold. 
• This is also known as the “slow start 
threshold” ssthresh. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1122
ssthresh 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1133
FFiigguurree 66..1111 BBeehhaavviioorr ooff TTCCPP 
CCoonnggeessttiioonn CCoonnttrrooll 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1144 
60 
50 
40 
20 
1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 
Time (seconds) 
70 
30 
10
FFaasstt RReettrraannssmmiitt 
• Coarse timeouts remained a problem, and Fast 
retransmit was added with TCP Tahoe. 
• Since the receiver responds every time a packet 
arrives, this implies the sender will see duplicate 
ACKs. 
Basic Idea:: use duplicate ACKs to signal lost packet. 
Fast Retransmit 
Upon receipt of three duplicate ACKs, the TCP Sender 
retransmits the lost packet. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1155
FFaasstt RReettrraannssmmiitt 
• Generally, fast retransmit eliminates about half 
the coarse-grain timeouts. 
• This yields roughly a 20% improvement in 
throughput. 
• Note – fast retransmit does not eliminate all 
the timeouts due to small window sizes at the 
source. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1166
Sender Receiver 
ACK 2 
FFiigguurree 66..1122 FFaasstt RReettrraannssmmiitt 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1177 
Packet 1 
Packet 2 
Packet 3 
Packet 4 
Packet 5 
Packet 6 
Retransmit 
packet 3 
ACK 1 
ACK 2 
ACK 2 
ACK 2 
ACK 6 
Fast Retransmit 
Based on three 
duplicate ACKs
FFiigguurree 66..1133 TTCCPP FFaasstt RReettrraannssmmiitt 
TTrraaccee 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1188 
60 
50 
40 
20 
1.0 2.0 3.0 4.0 5.0 6.0 7.0 
Time (seconds) 
70 
30 
10
FFaasstt RReeccoovveerryy 
• Fast recovery was added with TCP Reno. 
• Basic idea:: When fast retransmit detects 
three duplicate ACKs, start the recovery 
process from congestion avoidance region 
and use ACKs in the pipe to pace the 
sending of packets. 
Fast Recovery 
After Fast Retransmit, half cwnd and commence 
recovery from this point using linear additive increase 
‘primed’ by left over ACKs in pipe. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1199
MMooddiiffiieedd SSllooww SSttaarrtt 
• With fast recovery, slow start only 
occurs: 
–At cold start 
–After a coarse-grain timeout 
• This is the difference between 
TCP Tahoe and TCP Reno!! 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2200
MMaannyy TTCCPP ‘‘ffllaavvoorrss’’ 
• TCP New Reno 
• TCP SACK 
– requires sender and receiver both to 
support TCP SACK 
– possible state machine is complex. 
• TCP Vegas 
– adjusts window size based on difference 
between expected and actual RTT. 
• TCP Cubic 
CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2211
FFiigguurree 55..66 TThhrreeee--wwaayy TTCCPP 
HHaannddsshhaakkee 
CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2222
AAddaappttiivvee RReettrraannssmmiissssiioonnss 
RTT:: Round Trip Time between a pair of 
hosts on the Internet. 
• How to set the TimeOut value (RTO)? 
– The timeout value is set as a function of 
the expected RTT. 
– Consequences of a bad choice? 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2233
OOrriiggiinnaall AAllggoorriitthhmm 
• Keep a running average of RTT and 
compute TimeOut as a function of this 
RTT. 
– Send packet and keep timestamp ts . 
– When ACK arrives, record timestamp ta . 
SampleRTT = ta - ts 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2244
OOrriiggiinnaall AAllggoorriitthhmm 
Compute a weighted average: 
EEssttiimmaatteeddRRTTTT == αα xx EEssttiimmaatteeddRRTTTT ++ 
((11-- αα)) xx SSaammpplleeRRTTTT 
Original TCP spec: αα iinn rraannggee ((00..88,,00..99)) 
TTiimmeeOOuutt == 22 xx EEssttiimmaatteeddRRTTTT 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2255
KKaarrnn//PPaarrttiiddggee AAllggoorriitthhmm 
An obvious flaw in the original algorithm: 
Whenever there is a retransmission it is 
impossible to know whether to associate 
the ACK with the original packet or the 
retransmitted packet. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2266
FFiigguurree 55..1100 AAssssoocciiaattiinngg tthhee 
AACCKK?? 
Sender Receiver 
Original transmission 
Retransmission 
ACK 
Sender Receiver 
Original transmission 
ACK 
Retransmission 
(a) (b) 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2277
KKaarrnn//PPaarrttiiddggee AAllggoorriitthhmm 
1. Do not measure SSaammpplleeRRTTTT when 
sending packet more than once. 
2. For each retransmission, set TTiimmeeOOuutt 
to double the last TTiimmeeOOuutt. 
{ Note – this is a form of exponential 
backoff based on the believe that the 
lost packet is due to congestion.} 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2288
JJaaccoobbssoonn//KKaarreellss AAllggoorriitthhmm 
The problem with the original algorithm is that it did not 
take into account the variance of SampleRTT. 
DDiiffffeerreennccee == SSaammpplleeRRTTTT –– EEssttiimmaatteeddRRTTTT 
EEssttiimmaatteeddRRTTTT == EEssttiimmaatteeddRRTTTT ++ 
((δδ xx DDiiffffeerreennccee)) 
DDeevviiaattiioonn == δδ ((||DDiiffffeerreennccee|| - DDeevviiaattiioonn)) 
where δδ is a fraction between 0 and 1. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2299
JJaaccoobbssoonn//KKaarreellss AAllggoorriitthhmm 
TCP computes timeout using both the mean 
and variance of RTT 
TTiimmeeOOuutt == μμ xx EEssttiimmaatteeddRRTTTT 
++ ΦΦ xx DDeevviiaattiioonn 
where based on experience μμ == 11 and ΦΦ == 44. 
Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3300
TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 
SSuummmmaarryy 
• TCP interacts with routers in the subnet 
and reacts to implicit congestion 
notification (packet drop) by reducing the 
TCP sender’s congestion window. 
• TCP increases congestion window using 
slow start or congestion avoidance. 
• Currently, the two most common versions 
of TCP are New Reno and Cubic 
CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3311
TTCCPP NNeeww RReennoo 
• Two problem scenarios with TCP Reno 
– bursty losses, Reno cannot recover from 
bursts of 3+ losses 
– Packets arriving out-of-order can yield 
duplicate acks when in fact there is no 
loss. 
• New Reno solution – try to determine 
the end of a burst loss. 
CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3322
TTCCPP NNeeww RReennoo 
• When duplicate ACKs trigger a 
retransmission for a lost packet, 
remember the highest packet sent from 
window in recover. 
• Upon receiving an ACK, 
– if ACK < recover => partial ACK 
– If ACK ≥ recover => new ACK 
CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3333
TTCCPP NNeeww RReennoo 
• Partial ACK implies another lost packet: 
retransmit next packet, inflate window 
and stay in fast recovery. 
• New ACK implies fast recovery is over: 
starting from 0.5 x cwnd proceed with 
congestion avoidance (linear increase). 
• New Reno recovers from n losses in n 
round trips. 
CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3344

More Related Content

What's hot

ATM Networking Concept
ATM Networking ConceptATM Networking Concept
ATM Networking ConceptTushar Ranjan
 
The Data Link Layer
The Data Link LayerThe Data Link Layer
The Data Link Layerrobbbminson
 
Error Detection And Correction
Error Detection And CorrectionError Detection And Correction
Error Detection And CorrectionRenu Kewalramani
 
Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)k33a
 
Computer Networks - Error Detection & Error Correction
Computer Networks - Error Detection & Error CorrectionComputer Networks - Error Detection & Error Correction
Computer Networks - Error Detection & Error CorrectionSaikrishna Tanguturu
 
QOS (Quality of Services) - Computer Networks
 QOS (Quality of Services) - Computer Networks QOS (Quality of Services) - Computer Networks
QOS (Quality of Services) - Computer NetworksIIIT Manipur
 
Congestion control, slow start, fast retransmit
Congestion control, slow start, fast retransmit   Congestion control, slow start, fast retransmit
Congestion control, slow start, fast retransmit rajisri2
 
Transport protocols
Transport protocolsTransport protocols
Transport protocolsOnline
 
Lecture 7 8 ad hoc wireless media access protocols
Lecture 7 8 ad hoc wireless media access protocolsLecture 7 8 ad hoc wireless media access protocols
Lecture 7 8 ad hoc wireless media access protocolsChandra Meena
 
Introduction of tcp, ip & udp
Introduction of tcp, ip & udpIntroduction of tcp, ip & udp
Introduction of tcp, ip & udprahul kundu
 
Introduction to Data-Link Layer
Introduction to Data-Link LayerIntroduction to Data-Link Layer
Introduction to Data-Link LayerAbdullaziz Tagawy
 
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...Pallepati Vasavi
 
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSComputer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSDr. SELVAGANESAN S
 

What's hot (20)

ATM Networking Concept
ATM Networking ConceptATM Networking Concept
ATM Networking Concept
 
Computer networks - Channelization
Computer networks - ChannelizationComputer networks - Channelization
Computer networks - Channelization
 
The Data Link Layer
The Data Link LayerThe Data Link Layer
The Data Link Layer
 
Error Detection And Correction
Error Detection And CorrectionError Detection And Correction
Error Detection And Correction
 
Mobile Transport layer
Mobile Transport layerMobile Transport layer
Mobile Transport layer
 
Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)Transmission Control Protocol (TCP)
Transmission Control Protocol (TCP)
 
Transport layer
Transport layer Transport layer
Transport layer
 
Computer Networks - Error Detection & Error Correction
Computer Networks - Error Detection & Error CorrectionComputer Networks - Error Detection & Error Correction
Computer Networks - Error Detection & Error Correction
 
QOS (Quality of Services) - Computer Networks
 QOS (Quality of Services) - Computer Networks QOS (Quality of Services) - Computer Networks
QOS (Quality of Services) - Computer Networks
 
Congestion control, slow start, fast retransmit
Congestion control, slow start, fast retransmit   Congestion control, slow start, fast retransmit
Congestion control, slow start, fast retransmit
 
Transport protocols
Transport protocolsTransport protocols
Transport protocols
 
Lecture 7 8 ad hoc wireless media access protocols
Lecture 7 8 ad hoc wireless media access protocolsLecture 7 8 ad hoc wireless media access protocols
Lecture 7 8 ad hoc wireless media access protocols
 
Ip addressing classful
Ip addressing classfulIp addressing classful
Ip addressing classful
 
Introduction of tcp, ip & udp
Introduction of tcp, ip & udpIntroduction of tcp, ip & udp
Introduction of tcp, ip & udp
 
Introduction to Data-Link Layer
Introduction to Data-Link LayerIntroduction to Data-Link Layer
Introduction to Data-Link Layer
 
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...
 
Frame relay
Frame relayFrame relay
Frame relay
 
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSComputer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
 
Point to-point protocol (ppp)
Point to-point protocol (ppp)Point to-point protocol (ppp)
Point to-point protocol (ppp)
 
The medium access sublayer
 The medium  access sublayer The medium  access sublayer
The medium access sublayer
 

Viewers also liked

Java Input Output and File Handling
Java Input Output and File HandlingJava Input Output and File Handling
Java Input Output and File HandlingSunil OS
 
basics of file handling
basics of file handlingbasics of file handling
basics of file handlingpinkpreet_kaur
 
Routing Protocols and Concepts - Chapter 1
Routing Protocols and Concepts - Chapter 1Routing Protocols and Concepts - Chapter 1
Routing Protocols and Concepts - Chapter 1CAVC
 
14 file handling
14 file handling14 file handling
14 file handlingAPU
 
Java Course 8: I/O, Files and Streams
Java Course 8: I/O, Files and StreamsJava Course 8: I/O, Files and Streams
Java Course 8: I/O, Files and StreamsAnton Keks
 

Viewers also liked (7)

Socket System Calls
Socket System CallsSocket System Calls
Socket System Calls
 
Java Input Output and File Handling
Java Input Output and File HandlingJava Input Output and File Handling
Java Input Output and File Handling
 
basics of file handling
basics of file handlingbasics of file handling
basics of file handling
 
Routing Protocols and Concepts - Chapter 1
Routing Protocols and Concepts - Chapter 1Routing Protocols and Concepts - Chapter 1
Routing Protocols and Concepts - Chapter 1
 
14 file handling
14 file handling14 file handling
14 file handling
 
Java Course 8: I/O, Files and Streams
Java Course 8: I/O, Files and StreamsJava Course 8: I/O, Files and Streams
Java Course 8: I/O, Files and Streams
 
Socket programming
Socket programmingSocket programming
Socket programming
 

Similar to TCP congestion control

Tcp congestion control
Tcp congestion controlTcp congestion control
Tcp congestion controlAbdo sayed
 
Tcp congestion control (1)
Tcp congestion control (1)Tcp congestion control (1)
Tcp congestion control (1)Abdo sayed
 
Lecture 19 22. transport protocol for ad-hoc
Lecture 19 22. transport protocol for ad-hoc Lecture 19 22. transport protocol for ad-hoc
Lecture 19 22. transport protocol for ad-hoc Chandra Meena
 
Computer network (13)
Computer network (13)Computer network (13)
Computer network (13)NYversity
 
Designing TCP-Friendly Window-based Congestion Control
Designing TCP-Friendly Window-based Congestion ControlDesigning TCP-Friendly Window-based Congestion Control
Designing TCP-Friendly Window-based Congestion Controlsoohyunc
 
Mobile Transpot Layer
Mobile Transpot LayerMobile Transpot Layer
Mobile Transpot LayerMaulik Patel
 
Troubleshooting TCP/IP
Troubleshooting TCP/IPTroubleshooting TCP/IP
Troubleshooting TCP/IPvijai s
 
chapter 3.2 TCP.pptx
chapter 3.2 TCP.pptxchapter 3.2 TCP.pptx
chapter 3.2 TCP.pptxTekle12
 
Tcp Congestion Avoidance
Tcp Congestion AvoidanceTcp Congestion Avoidance
Tcp Congestion AvoidanceRam Dutt Shukla
 
Tcp performance simulationsusingns2
Tcp performance simulationsusingns2Tcp performance simulationsusingns2
Tcp performance simulationsusingns2Justin Frankel
 
Unit III IPV6 UDP
Unit III IPV6 UDPUnit III IPV6 UDP
Unit III IPV6 UDPsangusajjan
 
XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...
XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...
XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...The Linux Foundation
 
Computer network (5)
Computer network (5)Computer network (5)
Computer network (5)NYversity
 

Similar to TCP congestion control (20)

Tcp congestion control
Tcp congestion controlTcp congestion control
Tcp congestion control
 
Tcp congestion control (1)
Tcp congestion control (1)Tcp congestion control (1)
Tcp congestion control (1)
 
TCP_Congestion_Control.ppt
TCP_Congestion_Control.pptTCP_Congestion_Control.ppt
TCP_Congestion_Control.ppt
 
NE #1.pptx
NE #1.pptxNE #1.pptx
NE #1.pptx
 
Tcp congestion avoidance
Tcp congestion avoidanceTcp congestion avoidance
Tcp congestion avoidance
 
Lecture 19 22. transport protocol for ad-hoc
Lecture 19 22. transport protocol for ad-hoc Lecture 19 22. transport protocol for ad-hoc
Lecture 19 22. transport protocol for ad-hoc
 
Computer network (13)
Computer network (13)Computer network (13)
Computer network (13)
 
Designing TCP-Friendly Window-based Congestion Control
Designing TCP-Friendly Window-based Congestion ControlDesigning TCP-Friendly Window-based Congestion Control
Designing TCP-Friendly Window-based Congestion Control
 
Mobile Transpot Layer
Mobile Transpot LayerMobile Transpot Layer
Mobile Transpot Layer
 
Troubleshooting TCP/IP
Troubleshooting TCP/IPTroubleshooting TCP/IP
Troubleshooting TCP/IP
 
6610-l14.pptx
6610-l14.pptx6610-l14.pptx
6610-l14.pptx
 
Mobile comn.pptx
Mobile comn.pptxMobile comn.pptx
Mobile comn.pptx
 
chapter 3.2 TCP.pptx
chapter 3.2 TCP.pptxchapter 3.2 TCP.pptx
chapter 3.2 TCP.pptx
 
Tcp Congestion Avoidance
Tcp Congestion AvoidanceTcp Congestion Avoidance
Tcp Congestion Avoidance
 
Part9-congestion.pptx
Part9-congestion.pptxPart9-congestion.pptx
Part9-congestion.pptx
 
Tcp performance simulationsusingns2
Tcp performance simulationsusingns2Tcp performance simulationsusingns2
Tcp performance simulationsusingns2
 
Congestion control avoidance
Congestion control avoidanceCongestion control avoidance
Congestion control avoidance
 
Unit III IPV6 UDP
Unit III IPV6 UDPUnit III IPV6 UDP
Unit III IPV6 UDP
 
XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...
XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...
XPDS13: On Paravirualizing TCP - Congestion Control on Xen VMs - Luwei Cheng,...
 
Computer network (5)
Computer network (5)Computer network (5)
Computer network (5)
 

Recently uploaded

PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiessarkmank1
 
Thermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.pptThermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.pptDineshKumar4165
 
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Call Girls Mumbai
 
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARKOUSTAV SARKAR
 
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptxS1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptxSCMS School of Architecture
 
Hostel management system project report..pdf
Hostel management system project report..pdfHostel management system project report..pdf
Hostel management system project report..pdfKamal Acharya
 
Block diagram reduction techniques in control systems.ppt
Block diagram reduction techniques in control systems.pptBlock diagram reduction techniques in control systems.ppt
Block diagram reduction techniques in control systems.pptNANDHAKUMARA10
 
Introduction to Serverless with AWS Lambda
Introduction to Serverless with AWS LambdaIntroduction to Serverless with AWS Lambda
Introduction to Serverless with AWS LambdaOmar Fathy
 
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptxA CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptxmaisarahman1
 
Online food ordering system project report.pdf
Online food ordering system project report.pdfOnline food ordering system project report.pdf
Online food ordering system project report.pdfKamal Acharya
 
DeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesDeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesMayuraD1
 
Computer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to ComputersComputer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to ComputersMairaAshraf6
 
School management system project Report.pdf
School management system project Report.pdfSchool management system project Report.pdf
School management system project Report.pdfKamal Acharya
 
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...Arindam Chakraborty, Ph.D., P.E. (CA, TX)
 
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxOrlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxMuhammadAsimMuhammad6
 
NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...
NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...
NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...Amil baba
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VDineshKumar4165
 
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...drmkjayanthikannan
 

Recently uploaded (20)

PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
Thermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.pptThermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.ppt
 
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
 
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
 
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptxS1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
 
Integrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - NeometrixIntegrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - Neometrix
 
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced LoadsFEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
 
Hostel management system project report..pdf
Hostel management system project report..pdfHostel management system project report..pdf
Hostel management system project report..pdf
 
Block diagram reduction techniques in control systems.ppt
Block diagram reduction techniques in control systems.pptBlock diagram reduction techniques in control systems.ppt
Block diagram reduction techniques in control systems.ppt
 
Introduction to Serverless with AWS Lambda
Introduction to Serverless with AWS LambdaIntroduction to Serverless with AWS Lambda
Introduction to Serverless with AWS Lambda
 
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptxA CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
 
Online food ordering system project report.pdf
Online food ordering system project report.pdfOnline food ordering system project report.pdf
Online food ordering system project report.pdf
 
DeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesDeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakes
 
Computer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to ComputersComputer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to Computers
 
School management system project Report.pdf
School management system project Report.pdfSchool management system project Report.pdf
School management system project Report.pdf
 
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
Navigating Complexity: The Role of Trusted Partners and VIAS3D in Dassault Sy...
 
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxOrlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
 
NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...
NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...
NO1 Top No1 Amil Baba In Azad Kashmir, Kashmir Black Magic Specialist Expert ...
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - V
 
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
Unit 4_Part 1 CSE2001 Exception Handling and Function Template and Class Temp...
 

TCP congestion control

  • 1. TTCCPP CCoonnggeessttiioonn CCoonnttrrooll Lecture material taken from “Computer Networks A Systems Approach”, Fourth Edition,Peterson and Davie, Morgan Kaufmann, 2007. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 11
  • 2. TTCCPP CCoonnggeessttiioonn CCoonnttrrooll • Essential strategy :: The TCP host sends packets into the network without a reservation and then the host reacts to observable events. • Originally TCP assumed FIFO queuing. • Basic idea :: each source determines how much capacity is available to a given flow in the network. • ACKs are used to ‘pace’ the transmission of packets such that TCP is “self-clocking”. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 22
  • 3. AAIIMMDD ((AAddddiittiivvee IInnccrreeaassee // MMuullttiipplliiccaattiivvee DDeeccrreeaassee)) • CongestionWindow (cwnd) is a variable held by the TCP source for each connection. MaxWindow :: min (CongestionWindow , AdvertisedWindow) EffectiveWindow = MaxWindow – (LastByteSent -LastByteAcked) • cwnd is set based on the perceived level of congestion. The Host receives implicit (packet drop) or explicit (packet mark) indications of internal congestion. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 33
  • 4. AAddddiittiivvee IInnccrreeaassee ((AAII)) • Additive Increase is a reaction to perceived available capacity (referred to as congestion avoidance stage). • Frequently in the literature, additive increase is defined by parameter α (where the default is α = 1). • Linear Increase :: For each “cwnd’s worth” of packets sent, increase cwnd by 1 packet. • In practice, cwnd is incremented fractionally for each arriving ACK. increment = MSS x (MSS /cwnd) cwnd = cwnd + increment Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 44
  • 5. Source Destination Add one packet each RTT FFiigguurree 66..88 AAddddiittiivvee IInnccrreeaassee Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 55
  • 6. MMuullttiipplliiccaattiivvee DDeeccrreeaassee ((MMDD)) * Key assumption :: a dropped packet and resultant timeout are due to congestion at a router. • Frequently in the literature, multiplicative decrease is defined by parameter β (where the default is β = 0.5) Multiplicate Decrease:: TCP reacts to a timeout by halving cwnd. • Although defined in bytes, the literature often discusses cwnd in terms of packets (or more formally in MSS == Maximum Segment Size). • cwnd is not allowed below the size of a single packet. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 66
  • 7. AAIIMMDD ((AAddddiittiivvee IInnccrreeaassee // MMuullttiipplliiccaattiivvee DDeeccrreeaassee)) • It has been shown that AIMD is a necessary condition for TCP congestion control to be stable. • Because the simple CC mechanism involves timeouts that cause retransmissions, it is important that hosts have an accurate timeout mechanism. • Timeouts set as a function of average RTT and standard deviation of RTT. • However, TCP hosts only sample round-trip time once per RTT using coarse-grained clock. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 77
  • 8. FFiigguurree 66..99 TTyyppiiccaall TTCCPP SSaawwttooootthh PPaatttteerrnn Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 88 60 50 40 20 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 Time (seconds) 70 30 10 10.0
  • 9. SSllooww SSttaarrtt • Linear additive increase takes too long to ramp up a new TCP connection from cold start. • Beginning with TCP Tahoe, the slow start mechanism was added to provide an initial exponential increase in the size of cwnd. Remember mechanism by: slow start prevents a slow start. Moreover, slow start is slower than sending a full advertised window’s worth of packets all at once. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 99
  • 10. SSllooww SSttaarrtt • The source starts with cwnd = 1. • Every time an ACK arrives, cwnd is incremented. cwnd is effectively doubled per RTT “epoch”. • Two slow start situations:  At the very beginning of a connection {cold start}.  When the connection goes dead waiting for a timeout to occur (i.e, the advertized window goes to zero!) Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1100
  • 11. Source Destination Slow Start Add one packet per ACK FFiigguurree 66..1100 SSllooww SSttaarrtt Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1111
  • 12. SSllooww SSttaarrtt • However, in the second case the source has more information. The current value of cwnd can be saved as a congestion threshold. • This is also known as the “slow start threshold” ssthresh. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1122
  • 13. ssthresh Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1133
  • 14. FFiigguurree 66..1111 BBeehhaavviioorr ooff TTCCPP CCoonnggeessttiioonn CCoonnttrrooll Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1144 60 50 40 20 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 Time (seconds) 70 30 10
  • 15. FFaasstt RReettrraannssmmiitt • Coarse timeouts remained a problem, and Fast retransmit was added with TCP Tahoe. • Since the receiver responds every time a packet arrives, this implies the sender will see duplicate ACKs. Basic Idea:: use duplicate ACKs to signal lost packet. Fast Retransmit Upon receipt of three duplicate ACKs, the TCP Sender retransmits the lost packet. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1155
  • 16. FFaasstt RReettrraannssmmiitt • Generally, fast retransmit eliminates about half the coarse-grain timeouts. • This yields roughly a 20% improvement in throughput. • Note – fast retransmit does not eliminate all the timeouts due to small window sizes at the source. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1166
  • 17. Sender Receiver ACK 2 FFiigguurree 66..1122 FFaasstt RReettrraannssmmiitt Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1177 Packet 1 Packet 2 Packet 3 Packet 4 Packet 5 Packet 6 Retransmit packet 3 ACK 1 ACK 2 ACK 2 ACK 2 ACK 6 Fast Retransmit Based on three duplicate ACKs
  • 18. FFiigguurree 66..1133 TTCCPP FFaasstt RReettrraannssmmiitt TTrraaccee Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1188 60 50 40 20 1.0 2.0 3.0 4.0 5.0 6.0 7.0 Time (seconds) 70 30 10
  • 19. FFaasstt RReeccoovveerryy • Fast recovery was added with TCP Reno. • Basic idea:: When fast retransmit detects three duplicate ACKs, start the recovery process from congestion avoidance region and use ACKs in the pipe to pace the sending of packets. Fast Recovery After Fast Retransmit, half cwnd and commence recovery from this point using linear additive increase ‘primed’ by left over ACKs in pipe. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 1199
  • 20. MMooddiiffiieedd SSllooww SSttaarrtt • With fast recovery, slow start only occurs: –At cold start –After a coarse-grain timeout • This is the difference between TCP Tahoe and TCP Reno!! Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2200
  • 21. MMaannyy TTCCPP ‘‘ffllaavvoorrss’’ • TCP New Reno • TCP SACK – requires sender and receiver both to support TCP SACK – possible state machine is complex. • TCP Vegas – adjusts window size based on difference between expected and actual RTT. • TCP Cubic CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2211
  • 22. FFiigguurree 55..66 TThhrreeee--wwaayy TTCCPP HHaannddsshhaakkee CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2222
  • 23. AAddaappttiivvee RReettrraannssmmiissssiioonnss RTT:: Round Trip Time between a pair of hosts on the Internet. • How to set the TimeOut value (RTO)? – The timeout value is set as a function of the expected RTT. – Consequences of a bad choice? Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2233
  • 24. OOrriiggiinnaall AAllggoorriitthhmm • Keep a running average of RTT and compute TimeOut as a function of this RTT. – Send packet and keep timestamp ts . – When ACK arrives, record timestamp ta . SampleRTT = ta - ts Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2244
  • 25. OOrriiggiinnaall AAllggoorriitthhmm Compute a weighted average: EEssttiimmaatteeddRRTTTT == αα xx EEssttiimmaatteeddRRTTTT ++ ((11-- αα)) xx SSaammpplleeRRTTTT Original TCP spec: αα iinn rraannggee ((00..88,,00..99)) TTiimmeeOOuutt == 22 xx EEssttiimmaatteeddRRTTTT Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2255
  • 26. KKaarrnn//PPaarrttiiddggee AAllggoorriitthhmm An obvious flaw in the original algorithm: Whenever there is a retransmission it is impossible to know whether to associate the ACK with the original packet or the retransmitted packet. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2266
  • 27. FFiigguurree 55..1100 AAssssoocciiaattiinngg tthhee AACCKK?? Sender Receiver Original transmission Retransmission ACK Sender Receiver Original transmission ACK Retransmission (a) (b) Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2277
  • 28. KKaarrnn//PPaarrttiiddggee AAllggoorriitthhmm 1. Do not measure SSaammpplleeRRTTTT when sending packet more than once. 2. For each retransmission, set TTiimmeeOOuutt to double the last TTiimmeeOOuutt. { Note – this is a form of exponential backoff based on the believe that the lost packet is due to congestion.} Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2288
  • 29. JJaaccoobbssoonn//KKaarreellss AAllggoorriitthhmm The problem with the original algorithm is that it did not take into account the variance of SampleRTT. DDiiffffeerreennccee == SSaammpplleeRRTTTT –– EEssttiimmaatteeddRRTTTT EEssttiimmaatteeddRRTTTT == EEssttiimmaatteeddRRTTTT ++ ((δδ xx DDiiffffeerreennccee)) DDeevviiaattiioonn == δδ ((||DDiiffffeerreennccee|| - DDeevviiaattiioonn)) where δδ is a fraction between 0 and 1. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 2299
  • 30. JJaaccoobbssoonn//KKaarreellss AAllggoorriitthhmm TCP computes timeout using both the mean and variance of RTT TTiimmeeOOuutt == μμ xx EEssttiimmaatteeddRRTTTT ++ ΦΦ xx DDeevviiaattiioonn where based on experience μμ == 11 and ΦΦ == 44. Computer Networks: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3300
  • 31. TTCCPP CCoonnggeessttiioonn CCoonnttrrooll SSuummmmaarryy • TCP interacts with routers in the subnet and reacts to implicit congestion notification (packet drop) by reducing the TCP sender’s congestion window. • TCP increases congestion window using slow start or congestion avoidance. • Currently, the two most common versions of TCP are New Reno and Cubic CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3311
  • 32. TTCCPP NNeeww RReennoo • Two problem scenarios with TCP Reno – bursty losses, Reno cannot recover from bursts of 3+ losses – Packets arriving out-of-order can yield duplicate acks when in fact there is no loss. • New Reno solution – try to determine the end of a burst loss. CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3322
  • 33. TTCCPP NNeeww RReennoo • When duplicate ACKs trigger a retransmission for a lost packet, remember the highest packet sent from window in recover. • Upon receiving an ACK, – if ACK < recover => partial ACK – If ACK ≥ recover => new ACK CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3333
  • 34. TTCCPP NNeeww RReennoo • Partial ACK implies another lost packet: retransmit next packet, inflate window and stay in fast recovery. • New ACK implies fast recovery is over: starting from 0.5 x cwnd proceed with congestion avoidance (linear increase). • New Reno recovers from n losses in n round trips. CCoommppuutteerr NNeettwwoorrkkss:: TTCCPP CCoonnggeessttiioonn CCoonnttrrooll 3344