Transport Layer
Transport Layer
Transport Layer
Encapsulated unit created at the Network layer of the OSI model. Encapsulated unit created at the data link layer of the OSI
Packet contains Source and destination IP address along with Frame contains Source and destination MAC address along with
Top layer data Top layer data.
Segment is encapsulated with in a packet. Hence segment is the packet is encapsulated within a frame. Hence packet is the data
data part part
Thus, a packet typically contains logical address information Thus a frame typically contains physical address information.
Transport Layer
• The Transport layer is responsible for the delivery of a message from
one process to another.
Process to process means:
It is not just a source to destination delivery i.e from one computer to
another.
It is a delivery from a specific process on one computer to a specific
process on the other.
What a Network layer actually does?
It oversees source-to-destination delivery of individual packets , it
does not recognize any relationship between those packets.
It treats each one independently , as though each piece belongs to a
separate message.
How transport layer differ from network layer?
• The transport layer , ensures that the whole message arrives intact
and in order , overseeing both error control and flow control at the
source –to-destination level.
Transport Layer
Transport layer protocol
• A transport layer protocol can be either connectionless or
connection-oriented.
• UDP-Connectionless protocol-Simple
• TCP-Connection oriented protocol-Complex
• SCTP-Connection oriented protocol-Designed for Multimedia
application
• (Stream control transport protocol)
PDU(SEGMENT)
• In the Transport layer a message is normally divided into
transmittable segment.
• UDP treats each segment separately
• TCP creates a relationship between the segments using sequence
numbers.
Connectionless transport layer
• A connectionless transport layer treats each segment as an
independent packet and delivers it to the transport layer at the
destination machine.
• The packets are not numbered ; they may be delayed or lost or may
arrive out of sequence.
• There is no acknowledgement either.
• UDP is connectionless…
Connection –oriented transport layer
• A connection oriented transport layer makes a connection with the
transport layer at the destination machine first before delivering the
packets.
• After all the data is transferred , the connection is terminated.
• TCP and SCTP are Connection oriented…
Reliable versus unreliable
Transport layer service can be reliable or unreliable
• If the application layer program needs reliability,
TCP &SCTP protocol will implement flow and error control at the transport
layer . But it is slower and more complex service.
• If the application layer program does not need reliability, it means most real-
time application does not demand flow and error control,but it demand fast
service. So unreliable protocol UDP is used.
Question arises?
• If the data link layer is reliable and has flow and error control , do
we need this at transport layer too?
Answer
YES
• Reliability at the data link layer is between two
nodes ;
• we need reliability between two ends .
• Because the network layer in the internet is
unreliable.
• So we need to implement reliability at the
transport layer.
Types of data delivery
• This is the Port number used by the process running on the machine
• It is 16 bit long ,means port number can range from 0 to 65,535.
• If the source host is client an ephemeral port number is chosen by the
UDP for that particular process requested.
• If the source host is server the port number is a well-known port number.
Destination Port Number: