Unit 4 CN
Unit 4 CN
Unit 4 CN
Transport Layer
Transport Services
Elements of Transport protocols
Connection management
TCP and UDP protocols.
Introduction of Transport layer
Transport Layer is the second layer in the TCP/IP model and the
fourth layer in the OSI model.
The unit of data encapsulation in the Transport Layer is a segment.
The Transport Layer is not just another layer, it is the heart of the
whole protocol hierarchy.
Its task is to provide reliable, cost-effective data transport from the
source machine to destination machine, independently of the
physical network or network’s currently in use.
Without the transport layer, the whole concept of layered protocols
would make little sense.
Communication is provided using a logical connection, which means
that the two application layers, which can be located in different
parts of the globe, assume that there is an imaginary direct
connection through which they can send and receive messages.
Transport layer Services
The main role of the transport layer is to provide
the communication services directly to the
application processes running on different hosts.
The transport layer protocols are implemented in
the end systems but not in the network routers.
A computer network provides more than one protocol
to the network applications. For example, TCP and
UDP are two transport layer protocols that provide a
different set of services to the network layer.
All transport layer protocols provide
multiplexing/demultiplexing service.
It also provides other services such as reliable data
transfer, bandwidth guarantees, and delay guarantees.
Each of the applications in the application layer has
the ability to send a message by using TCP or UDP.
The application communicates by using either of
these two protocols. Both TCP and UDP will then
communicate with the internet protocol in the
internet layer.
The applications can read and write to the transport
layer. Therefore, we can say that communication is a
two-way process.
Services Provided to the Upper Layer:
The ultimate goal of the transport layer is to provide efficient,
reliable, and cost-effective services to its users, normally
processes in the application layer.
To achieve this goal, the Transport layer makes use of the
services provided by the network layer.
The hardware or software within the transport layer that
does the work is called the Transport entity.
The transport entity can be located in the OS kernel .
The relationship of the network, transport & application
layers is shown in below figure
At the sender’s side: The transport layer receives
data (message) from the Application layer and then
performs Segmentation, divides the actual message
into segments, adds source and destination’s port
numbers into the header of the segment, and
transfers the message to the Network layer.
At the receiver’s side: The transport layer receives
data from the Network layer, reassembles the
segmented data, reads its header, identifies the port
number, and forwards the message to the
appropriate port in the Application layer.
In network layer, there are two types of network service,
connection-oriented and connectionless, there are also two
types of transport service. The connection-oriented
transport service is similar to the connection-oriented
network service in many ways. The connectionless
transport service is also very similar to the connectionless
network service.
In both cases, connections have three phases:
establishment, data transfer, and release.
Addressing and flow control are also similar in both layers.
The transport code runs entirely on the users machines ,
but the network layer mostly runs on the routers, which
are operated by the carrier.
Transport Service Primitives
To allow users to access the transport service, the transport
layer must provide some operations to application programs,
that is, a transport service interface. Each transport service
has its own interface.
The transport service is similar to the network service, but
there are also some important differences. The main
difference is that the network service is intended to model
the service offered by real networks and all. Real networks
can lose packets, so the network service is generally
unreliable.
The connection-oriented transport service, in contrast, is
reliable. Of course, real networks are not error-free, but that
is precisely the purpose of the transport layer—to provide a
reliable service on top of an unreliable network.
A second difference between the network service and
transport service is that the services are intended for. The
network service is used only by the transport entities. Few
users write their own transport entities, and thus few users or
programs ever (meaning always/forever/still) see the bare
network service.
To get an idea of what a transport service might be like,
consider the five primitives listed in below Fig.
Figure : The primitives for a simple transport service.