SlideShare a Scribd company logo
TRANSPORT LAYER
TRANSPORT LAYER
Transport layer provides logical communication between application
process running on different host.
Application processes use the logical communication provided by the
transport layer to send messages to each other, free of the worry
about details of the physical infrastructure used to carry these
messages.
SERVICES PROVIDED TO UPPER
LAYERGoal of the transport layer is to efficient, reliable and cost effective service
to application layer.
To provide the service, transport layer uses service provided by network
layer.
Hardware and software within the transport layer that provides service is
called transport layer entity.
Transport layer provides two types service to application layer.
 Connection oriented service
 Connectionless service
Quality of Service
It can be said that primary function of transport layer is, enhancing the QoS
provided by network layer.
Transport layer allows user to specify some minimum, acceptable and desired
value for quality of service parameters at the time of connection set up.
list of the quality of parameters are given here.
The process of negotiating QoS parameter while
Connection establishment is called option negotiation.
Connection Establishment Delay
Connection Establishment Fail
Probability
Throughput
Transit Delay
Residual error date
Protection
Priority
Resilience
Transport Service Primitives
Transport service primitives allows transport user like application programs to
access transport service.
Difference between network service and transport service.
1. network service is used only by transport layer, while transport service is
used by number of application programs.
2. network layer service model services offered by real network, real network
can lost the packet, so network layer services are not 100% reliable.
Transport layer services are reliable, it provides reliable service using
unreliable network.
The primitives for a simple transport service.
Transport Service Primitives
Listen: executed by server. It means server is ready to accept
connection. It blocks the process of server until connection request
comes.
Connect: executed by client to request the connection. It sends
connection req. TPDU(transport protocol data unit) (packet) to server.
If server is able to handle connection then it sends Connection
accepted TPDU.
Send: executed to send data to other end.
Receive: when ever client or server is waiting for data, It executes
Receive primitive. This is also blocking primitive.
Disconnect: to disconnect connection. Two variants of disconnect.
1. Asymmetric: either side issues disconnect, connection will be
released.
2. Symmetric: both the side need to separately execute disconnect.
Transport Service Primitives
A state diagram for a simple connection management scheme. Transitions labeled in italics are caused by
packet arrivals. The solid lines show the client's state sequence. The dashed lines show the server's state
sequence.
Berkeley Sockets
Berkeley Socket Primitives for
ELEMENTS OF TRANSPORT
PROTOCOLAddressing
TSAPs, NSAPs and transport
ELEMENTS OF TRANSPORT
PROTOCOL
CONNECTION ESTABLISHMENT
Scenarios for establishing a connection using a three-way handshake. CR denotes
CONNECTION REQUEST.
(a) Normal operation,
(b) Old CONNECTION REQUEST appearing out of nowhere.
CONNECTION RELEASE
Connection at transport can be released in two way.
1. asymmetric: if one of host terminates connection, then in both the
direction, data communication will be terminated.
2. symmetric: if one of the host disconnects connection, then it can
not send the data but it can receive it.
CONNECTION RELEASE
Asymmetric Release
Abrupt disconnection with loss of data.
CONNECTION RELEASE
(a) Normal case of a three-way handshake. (b) final
ACK lost.
CONNECTION RELEASE
(c) Response DR lost (d) Response lost and
subsequent DRs lost.
CONNECTION RELEASE
TCP Connection Release uses symmetric approach. It is called Four
Way handshaking for connection termination.
FLOW CONTROL & BUFFERING
Transport layer manages end to end to flow. If the receiver is not able to
cope with the flow of data, then data flow should be control from sender
side, that part is done on Transport layer.
Data link layer is also doing flow control, but it controls flow of data
between adjacent nodes in path from source to destination.
Reasons of packet loss at receiver is slow processing speed or
insufficient buffer to store the data.
Buffer are allocated at sender and receiver side. If the network service is
reliable, so every send TPDU sent will be delivered to receiver and will be
buffered and processes at receiver, so no need to keep buffer at sender.
But if network service is unreliable and receiver may not able to handle
every incoming TPDU then sender should also keep a buffer, where copy
of TPDU resides until it’s ACK comes.
FLOW CONTROL & BUFFERING
Buffers can be allocate in fixed size when connection sets up or
buffer can be varied dynamically according to free memory. First
case is called static buffer allocation.
(a) Chained fixed-size buffers. (b) Chained variable-sized buffers. (c) One large circular buffer per connection.
FLOW CONTROL & BUFFERING
Dynamic Buffer Allocation: as connection are opened and closed,
memory available changes, so sender and receiver dynamically adjust
buffer allocations.
In dynamic buffer allocation, initially sender will request certain
number of buffers based on perceive need. receiver will grant as
many buffers as it can.Sender Receiver
<Req. 8 buffers>
<Buff Alloc. 4>
<Seq.:0,
data=m0>
< Seq.:1,
data=m1>
< Seq.:2, data=m2
> <Ack:2, Buf:2>
<Seq.:3,
data=m3><Seq.:4,
data=m4>
MULTIPLEXING
(a) Upward multiplexing. (b) Downward
multiplexing.
CRASH RECOVERY
Hosts and routers are subject to crash.
router crash is easier to handle since transport entities are alive at the host,
routers are only intermediate nodes which forwards packet, they do not have
transport layer entity.
How to recover from host crashes?
One client(host) is sending a file to server(receiver host). Transport layer at
server simply passes TPDU to transport layer. While transmission was on going,
server crashes.
Server crashes and comes up -> table initiated, does not know where it was?
Server sends a broadcast TPDU to all host, announcing that it had just crashed
and requesting that its clients inform it about status of all open connection.
Each client can be in one of two states:
S0: no outstanding TPDU
S1: one TPDU outstanding
CRASH RECOVERY
Now it seems that if TPDU is outstanding, client should transmit it, but there are
can be different hidden situations.
1. if server has first sent ACK and before it can send TPDU to next layer, server
crashes. In this case, client will get ACK so it will not retransmit, and TPDU is
lost by server.
2. if server first sends packet to next layer, then it crashes before it can send
ACK. In this case though server has already received TPDU, client thinks TPDU is
lost and it will retransmit.
Server(Receiving host) can be programmed in two ways, 1. ACK first 2. write
first
Three events are possible at server, sending ACK(A), sending packet to next
layer(W), crashing (C).
Three event can occur in six different case: AC(W) AWC C(AW), C(WA) WAC
WC(A)
Client(sending host) can be programmed in four ways, 1. always retransmit last
TPDU, 2. never retransmit last TPDU, 3. retransmit only in S0, 4. retransmit only
CRASH RECOVERY
Different combinations of client and server strategy.
UDP
User datagram protocol(UDP) is used to send and receive data without
establishing connection.
UDP packets is consist of 8 byte header followed by data.
UDP length includes 8byte header and data, size of whole segment.
UDP checksum is optional, stored as 0 if not computed.
The UDP header.
UDP
UDP does not do flow control, error control and retransmission if
packet gets lost.
Area where UDP is useful is client server application. Client sends
short request to server and gets short reply back.
Application that uses UDP this way is DNS.
If a host needs IP address of www.abc.com, it will send UDP packet to
server, server will reply with UDP packet that contains IP address of
site.
TCP
Transmission Control Protocol (TCP) was designed to provide reliable
end to end stream over unreliable network.
TCP service is obtain by creating a socket at both client and server
side. Each socket has socket address that consist of IP address and
port number.
Before sending data, connection must be established between
sending and receiving machine.
One socket can be used to establish many connection, many sender
can connect with same receiver socket. TCP connections are identified
by pair of sockets at both the end.
TCP connection are full duplex and point to point. TCP does not
support multicast and broadcast.
TCP connection is byte stream, not a message stream.
TCP
Sending and receiving TCP entities exchange data in form of segment.
TCP segment consist of 20 byte header plus optional part followed by data.
When sender transmits a segment, it also starts timer. When segment arrives
at destination, it sends acknowledgment. Acknowledgment contains equal to
sequence number of next data.
If timer for segment expires and acknowledgment does not reach to sender,
sender infers that packet is not delivered to receiver and it retransmits the
segment.
TCP HEADER
TCP HEADER
TCP HEADER
Options available with TCP
1. NAK(negative acknowledgment): host can send negative
acknowledgment, it specifies sequence number of data not yet
received.
2. timestamp: time stamp of the event when packet is send/received,
this option is used to calculate RTT(round trip time at transport layer)
3. TCP payload: host can specify maximum TCP payload(data in TCP
packet) size it is willing to accept.
TCP CONNECTION ESTABLISHMENT
TCP connection is established by Three way handshaking:
TCP CONNECTION RELEASE
TCP Connection Release uses symmetric approach. It is called Four
Way handshaking for connection termination.

More Related Content

PPTX
Network layer - design Issues
PPT
Unit 5 Application Layer
PPTX
Transport layer
PPT
Ip addressing classful
PPTX
Transport layer protocol
PPTX
2 phase locking protocol DBMS
PPTX
TCP/IP 3-way Handshake
PPTX
Network software
Network layer - design Issues
Unit 5 Application Layer
Transport layer
Ip addressing classful
Transport layer protocol
2 phase locking protocol DBMS
TCP/IP 3-way Handshake
Network software

What's hot (20)

PPSX
Issues in Data Link Layer
PPTX
Electronic mail - Computer Networks
PPTX
Single source Shortest path algorithm with example
PPTX
Multiple Access Protocal
PPT
Transport services
PPTX
Computer Network - Network Layer
PPTX
Data link layer
PPT
Congestion control and quality of service
PPTX
HDLC(High level Data Link Control)
PPT
Error detection correction (CRC)
PPT
Unit 3 Network Layer PPT
PPTX
Tcp header/IP Header/Authentication header
PPT
Error detection and correction
PPTX
Transport Layer Services : Multiplexing And Demultiplexing
PPT
Chapter 4 data link layer
PPTX
Application layer protocols
PDF
Transport layer services
PPTX
MEDIUM ACCESS CONTROL
PPTX
Transport layer
PPTX
Lock based protocols
Issues in Data Link Layer
Electronic mail - Computer Networks
Single source Shortest path algorithm with example
Multiple Access Protocal
Transport services
Computer Network - Network Layer
Data link layer
Congestion control and quality of service
HDLC(High level Data Link Control)
Error detection correction (CRC)
Unit 3 Network Layer PPT
Tcp header/IP Header/Authentication header
Error detection and correction
Transport Layer Services : Multiplexing And Demultiplexing
Chapter 4 data link layer
Application layer protocols
Transport layer services
MEDIUM ACCESS CONTROL
Transport layer
Lock based protocols
Ad

Similar to Transport layer (20)

PPTX
Transport_Layer (1).pptx
PPTX
Mcseminar
PPTX
UNIT 5 TRANSPORT LAYER AND APPLICATION LAYER.pptx
PPTX
Transport_Layer_Protocols.pptx
PDF
connectionestablishmentflowandcongestioncontrol-190130165746.pdf
PPTX
Connection Establishment & Flow and Congestion Control
PPTX
Unit V computer network notes for study.
PPT
Jaimin chp-6 - transport layer- 2011 batch
PPTX
Mobile Transpot Layer
PDF
Chap 5TransportLayer.pdfdistancevectorroutingandalgorithmcomputernetworks
PPTX
cCN UNIT4.pptxhomijo,k,ojik,m9uhgyh9ui,polo,0im
PPTX
Chapter Five - Transport Layer.pptx
PDF
Chapter03 sg
PPTX
Lec6
PDF
Chapter3 transport layer
PPT
Transport layer issues and challenges - Guide
PPT
Ch3 transport layer Network
PPTX
CNT - Module 1.Introduction to CN-OSI layers
DOCX
transport layer
DOCX
TCP.docx
Transport_Layer (1).pptx
Mcseminar
UNIT 5 TRANSPORT LAYER AND APPLICATION LAYER.pptx
Transport_Layer_Protocols.pptx
connectionestablishmentflowandcongestioncontrol-190130165746.pdf
Connection Establishment & Flow and Congestion Control
Unit V computer network notes for study.
Jaimin chp-6 - transport layer- 2011 batch
Mobile Transpot Layer
Chap 5TransportLayer.pdfdistancevectorroutingandalgorithmcomputernetworks
cCN UNIT4.pptxhomijo,k,ojik,m9uhgyh9ui,polo,0im
Chapter Five - Transport Layer.pptx
Chapter03 sg
Lec6
Chapter3 transport layer
Transport layer issues and challenges - Guide
Ch3 transport layer Network
CNT - Module 1.Introduction to CN-OSI layers
transport layer
TCP.docx
Ad

Recently uploaded (20)

DOCX
573137875-Attendance-Management-System-original
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
CH1 Production IntroductoryConcepts.pptx
PDF
Digital Logic Computer Design lecture notes
PDF
Well-logging-methods_new................
PPTX
additive manufacturing of ss316l using mig welding
PDF
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
PPTX
Welding lecture in detail for understanding
PDF
PPT on Performance Review to get promotions
PPTX
Construction Project Organization Group 2.pptx
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PPTX
UNIT 4 Total Quality Management .pptx
PPTX
Foundation to blockchain - A guide to Blockchain Tech
PPTX
web development for engineering and engineering
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PDF
Operating System & Kernel Study Guide-1 - converted.pdf
PPTX
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
PDF
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PPTX
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
573137875-Attendance-Management-System-original
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
CH1 Production IntroductoryConcepts.pptx
Digital Logic Computer Design lecture notes
Well-logging-methods_new................
additive manufacturing of ss316l using mig welding
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
Welding lecture in detail for understanding
PPT on Performance Review to get promotions
Construction Project Organization Group 2.pptx
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
UNIT 4 Total Quality Management .pptx
Foundation to blockchain - A guide to Blockchain Tech
web development for engineering and engineering
Model Code of Practice - Construction Work - 21102022 .pdf
Operating System & Kernel Study Guide-1 - converted.pdf
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...

Transport layer

  • 2. TRANSPORT LAYER Transport layer provides logical communication between application process running on different host. Application processes use the logical communication provided by the transport layer to send messages to each other, free of the worry about details of the physical infrastructure used to carry these messages.
  • 3. SERVICES PROVIDED TO UPPER LAYERGoal of the transport layer is to efficient, reliable and cost effective service to application layer. To provide the service, transport layer uses service provided by network layer. Hardware and software within the transport layer that provides service is called transport layer entity. Transport layer provides two types service to application layer.  Connection oriented service  Connectionless service
  • 4. Quality of Service It can be said that primary function of transport layer is, enhancing the QoS provided by network layer. Transport layer allows user to specify some minimum, acceptable and desired value for quality of service parameters at the time of connection set up. list of the quality of parameters are given here. The process of negotiating QoS parameter while Connection establishment is called option negotiation. Connection Establishment Delay Connection Establishment Fail Probability Throughput Transit Delay Residual error date Protection Priority Resilience
  • 5. Transport Service Primitives Transport service primitives allows transport user like application programs to access transport service. Difference between network service and transport service. 1. network service is used only by transport layer, while transport service is used by number of application programs. 2. network layer service model services offered by real network, real network can lost the packet, so network layer services are not 100% reliable. Transport layer services are reliable, it provides reliable service using unreliable network. The primitives for a simple transport service.
  • 6. Transport Service Primitives Listen: executed by server. It means server is ready to accept connection. It blocks the process of server until connection request comes. Connect: executed by client to request the connection. It sends connection req. TPDU(transport protocol data unit) (packet) to server. If server is able to handle connection then it sends Connection accepted TPDU. Send: executed to send data to other end. Receive: when ever client or server is waiting for data, It executes Receive primitive. This is also blocking primitive. Disconnect: to disconnect connection. Two variants of disconnect. 1. Asymmetric: either side issues disconnect, connection will be released. 2. Symmetric: both the side need to separately execute disconnect.
  • 7. Transport Service Primitives A state diagram for a simple connection management scheme. Transitions labeled in italics are caused by packet arrivals. The solid lines show the client's state sequence. The dashed lines show the server's state sequence.
  • 11. CONNECTION ESTABLISHMENT Scenarios for establishing a connection using a three-way handshake. CR denotes CONNECTION REQUEST. (a) Normal operation, (b) Old CONNECTION REQUEST appearing out of nowhere.
  • 12. CONNECTION RELEASE Connection at transport can be released in two way. 1. asymmetric: if one of host terminates connection, then in both the direction, data communication will be terminated. 2. symmetric: if one of the host disconnects connection, then it can not send the data but it can receive it.
  • 13. CONNECTION RELEASE Asymmetric Release Abrupt disconnection with loss of data.
  • 14. CONNECTION RELEASE (a) Normal case of a three-way handshake. (b) final ACK lost.
  • 15. CONNECTION RELEASE (c) Response DR lost (d) Response lost and subsequent DRs lost.
  • 16. CONNECTION RELEASE TCP Connection Release uses symmetric approach. It is called Four Way handshaking for connection termination.
  • 17. FLOW CONTROL & BUFFERING Transport layer manages end to end to flow. If the receiver is not able to cope with the flow of data, then data flow should be control from sender side, that part is done on Transport layer. Data link layer is also doing flow control, but it controls flow of data between adjacent nodes in path from source to destination. Reasons of packet loss at receiver is slow processing speed or insufficient buffer to store the data. Buffer are allocated at sender and receiver side. If the network service is reliable, so every send TPDU sent will be delivered to receiver and will be buffered and processes at receiver, so no need to keep buffer at sender. But if network service is unreliable and receiver may not able to handle every incoming TPDU then sender should also keep a buffer, where copy of TPDU resides until it’s ACK comes.
  • 18. FLOW CONTROL & BUFFERING Buffers can be allocate in fixed size when connection sets up or buffer can be varied dynamically according to free memory. First case is called static buffer allocation. (a) Chained fixed-size buffers. (b) Chained variable-sized buffers. (c) One large circular buffer per connection.
  • 19. FLOW CONTROL & BUFFERING Dynamic Buffer Allocation: as connection are opened and closed, memory available changes, so sender and receiver dynamically adjust buffer allocations. In dynamic buffer allocation, initially sender will request certain number of buffers based on perceive need. receiver will grant as many buffers as it can.Sender Receiver <Req. 8 buffers> <Buff Alloc. 4> <Seq.:0, data=m0> < Seq.:1, data=m1> < Seq.:2, data=m2 > <Ack:2, Buf:2> <Seq.:3, data=m3><Seq.:4, data=m4>
  • 20. MULTIPLEXING (a) Upward multiplexing. (b) Downward multiplexing.
  • 21. CRASH RECOVERY Hosts and routers are subject to crash. router crash is easier to handle since transport entities are alive at the host, routers are only intermediate nodes which forwards packet, they do not have transport layer entity. How to recover from host crashes? One client(host) is sending a file to server(receiver host). Transport layer at server simply passes TPDU to transport layer. While transmission was on going, server crashes. Server crashes and comes up -> table initiated, does not know where it was? Server sends a broadcast TPDU to all host, announcing that it had just crashed and requesting that its clients inform it about status of all open connection. Each client can be in one of two states: S0: no outstanding TPDU S1: one TPDU outstanding
  • 22. CRASH RECOVERY Now it seems that if TPDU is outstanding, client should transmit it, but there are can be different hidden situations. 1. if server has first sent ACK and before it can send TPDU to next layer, server crashes. In this case, client will get ACK so it will not retransmit, and TPDU is lost by server. 2. if server first sends packet to next layer, then it crashes before it can send ACK. In this case though server has already received TPDU, client thinks TPDU is lost and it will retransmit. Server(Receiving host) can be programmed in two ways, 1. ACK first 2. write first Three events are possible at server, sending ACK(A), sending packet to next layer(W), crashing (C). Three event can occur in six different case: AC(W) AWC C(AW), C(WA) WAC WC(A) Client(sending host) can be programmed in four ways, 1. always retransmit last TPDU, 2. never retransmit last TPDU, 3. retransmit only in S0, 4. retransmit only
  • 23. CRASH RECOVERY Different combinations of client and server strategy.
  • 24. UDP User datagram protocol(UDP) is used to send and receive data without establishing connection. UDP packets is consist of 8 byte header followed by data. UDP length includes 8byte header and data, size of whole segment. UDP checksum is optional, stored as 0 if not computed. The UDP header.
  • 25. UDP UDP does not do flow control, error control and retransmission if packet gets lost. Area where UDP is useful is client server application. Client sends short request to server and gets short reply back. Application that uses UDP this way is DNS. If a host needs IP address of www.abc.com, it will send UDP packet to server, server will reply with UDP packet that contains IP address of site.
  • 26. TCP Transmission Control Protocol (TCP) was designed to provide reliable end to end stream over unreliable network. TCP service is obtain by creating a socket at both client and server side. Each socket has socket address that consist of IP address and port number. Before sending data, connection must be established between sending and receiving machine. One socket can be used to establish many connection, many sender can connect with same receiver socket. TCP connections are identified by pair of sockets at both the end. TCP connection are full duplex and point to point. TCP does not support multicast and broadcast. TCP connection is byte stream, not a message stream.
  • 27. TCP Sending and receiving TCP entities exchange data in form of segment. TCP segment consist of 20 byte header plus optional part followed by data. When sender transmits a segment, it also starts timer. When segment arrives at destination, it sends acknowledgment. Acknowledgment contains equal to sequence number of next data. If timer for segment expires and acknowledgment does not reach to sender, sender infers that packet is not delivered to receiver and it retransmits the segment.
  • 30. TCP HEADER Options available with TCP 1. NAK(negative acknowledgment): host can send negative acknowledgment, it specifies sequence number of data not yet received. 2. timestamp: time stamp of the event when packet is send/received, this option is used to calculate RTT(round trip time at transport layer) 3. TCP payload: host can specify maximum TCP payload(data in TCP packet) size it is willing to accept.
  • 31. TCP CONNECTION ESTABLISHMENT TCP connection is established by Three way handshaking:
  • 32. TCP CONNECTION RELEASE TCP Connection Release uses symmetric approach. It is called Four Way handshaking for connection termination.