3. What is TCP
TCP Uses
TCP Connection Creation
Flow Control
Error Control
Congestion Control
Sliding Windows Protocol
Purpose of sliding windows protocol
QUESTIONS
Sequence
3
4. What is TCP ?
4
TCP (Transmission Control Protocol ) is a transport layer Process
to Process Data delivery protocol . Its main characteristics are:
Connection oriented
Reliable
Full Duplex
Bytes steams
5. Connection oriented
5
Connection oriented means:
A connection is established before any data is transferred
If the connection can’t be established, the user program is
notified
If an established connection is interrupted, the user program
is notified
6. Reliable
6
Reliable means:
Each and every transmission of Data is Acknowledged by Receiver
If the acknowledgement is not received with in specified time, data
is retransmitted
7. Byte Streams
7
Byte Stream means:
Connection is treated as stream of Bytes
The user application does not need to package data in individual
Datagrams
8. Uses of TCP
8
TCP is used for those services where error free and reliable Data
transmission is required. For example following well known services
use TCS as transport layer Protocol.
Service / Protocol Port Number
Used
Description
HTTP 80 Hyper text transfer protocol
SMTP 25 Simple mail transfer protocol
FTP 21 File transfer protocol
SSH 22 Secure shell
TELNET 23 Terminal Network
9. TCP Connection Creation
9
3 Way Hand Shake : Before any Data transfer TCP establishes a
connection using 3 Way Hand Shake mechanism
11. 3 Way Hand Shake
Client : I want to establish a connection and I
will transfer Data with initial sequence number
8000 (Syn Packet)
Server : OK. I received your syn, My intial
sequence number will be 15000 and expect
your Data Starting with Byte number 8001 (Syn
+ Ack Packet)
Client : Got it. You start your data transfer
starting with Byte number 15001 (Ack Packet)
11
15. Flow Control
TCP uses flow control to balance the rate at which sender
sends Data and receiver receives it.
Messages
are pushed
1
Segements are pushed
2
Messages
are pulled
3
Flow control feedback
4
Flow control
feedback
5
15
16. Flow Control : How it works
Receiver advertises spare room (available buffer size) by
including value of rwind (receive window) in segments.
Sender limits Data transfer size to rwind avoiding the
receiver to overflow
16
17. Error Control
TCP is a reliable Transport layer protocol . It sends Data
end to end without error, in order, and without any part lost
or duplicated
Error Control in TCP is achieved through the use of three
tools :
1. Checksum
2. Acknowledgement
3. Time out
17
18. Congestion Control
TCP uses a congestion window and a congestion policy that
avoid congestion and detect and alleviate congestion after it
has occurred.
18
19. Congestion Control
In Slow Start algorithm, the size of Congestion window (cwnd) exponentially
increases until it reaches a threshold.
cwnd
1
cwnd
2
RTT
cwnd
4
RTT
cwnd
8
RTT
19
20. Congestion Control
In the congestion avoidance algorithm the size of the congestion window
increases additively until congestion is detected.
20
21. Sliding Window Protocol
Sliding window is lesser of receiver (rwnd) and congestion
(cwnd) windows
The source does not have to send a full window’s worth of
data
21
23. Purpose Of Sliding Window Protocol
Sliding window is used :
To make the transmission more efficient
To prevent the receiver from overwhelming with data
To prevent the network from Congestion and loss free
transmission
23
HTTP= used in internet browsing from web browser such mozilla firefox, chrome etc. FTP = a protocol used for file (data ) transfer between server and a client
SSH= used for securely managing and configuring servers via a terminal. TELNET= also used for remotely connecting and managing of servers but the connection is unsecured as oppose to SSH. SMTP = used in mail transfer