COMPUTER NETWORKS CS610 Lecture-36 Hammad Khalid Khan
Review Lecture 35 UDP datagram Format UDP Encapsulation TCP: Reliable Transport Service The Need For Reliable Transport Service Provided by TCP End-to-End Service and Datagrams Achieving Reliablility
Packet Loss and Retransmission How does TCP achieve Reliability? Retransmission An Acknowledgement is used to verify that data has arrived successfully. If Acknowledgement does not arrive, the previous data is retransmitted.
Packet Loss and Retransmission
How Long Should TCP Wait Before Retransmitting? Time for acknowledgement to arrive depends on Distance to destination Current traffic conditions Multiple connections can be opened simultaneously. Traffic conditions change rapidly.
Adaptive Retransmission Set a timer. It sounds so easy, but …What time interval? Too long? You are spending time waiting for something that is just not going to happen. Too short? You will resend needlessly.
Adaptive Retransmission Keep estimate of round trip time on each connection Use current estimate to set transmission timer Know as Adaptive Retransmission Key to TCP’s success
Comparison of Retransmission Times
Buffers, Flow Control & Windows
Three-Way Handshake to Close a Connection
Three-way Handshake to Begin a Connection This will not mean much until you look at the packets, but SYN Randomly chosen sequence number, S1:0 SYN + ACK S2:S1+1 ACK S1+1:S2+1
Summary Packet Loss and Retransmission Adaptive Retransmission Buffers, Flow Control & Windows Three-Way Handshake