33 Transport Layer
33 Transport Layer
A transport layer protocol needs a pair of socket addresses: the client socket address and the server socket address.
These four pieces of information are part of the IP header and the transport layer protocol header.
The IP header contains the IP addresses;
the UDP or TCP header contains the port numbers.
Demultiplexing
Multiplexing: At the sender site, there may be several processes that need to send packets.
However, there is only one transport layer protocol at any time. This is a many-to-one
relationship and requires multiplexing. The protocol accepts messages from different
processes, differentiated by their assigned port numbers. After adding the header, the
transport layer passes the packet to the network layer.
Demultiplexing : At the receiver site, the relationship is one-to-many and requires
demultiplexing. The transport layer receives datagrams from the network layer. After error
checking and dropping of the header, the transport layer delivers each message to the
appropriate process based on the port number.
Multiplexing and demultiplexing
Reference
•Behrouz Forouzan, “Data Communication and
Networking”, McGraw Hill
14
Thank
You
Connectionless Service(UDP)
In a connectionless service, the packets are sent from one party to another with no need
for connection establishment or connection release. The packets are not numbered; they
may be delayed or lost or may arrive out of sequence. There is no acknowledgment either.
Connection Oriented Service(TCP and SCTP)
In a connection-oriented service, a connection is first established between the sender and
the receiver. Data are transferred.
Reliable Versus Unreliable
If the application layer program needs reliability, we use a reliable transport layer protocol by
implementing flow and error control at the transport layer. This means a slower and more
complex service. (TCP and SCTP)
On the other hand, if the application program does not need reliability because it uses its own
flow and error control mechanism or it needs fast service or the nature of the service does not
demand flow and error control (real-time applications), then an unreliable protocol can be
used.(UDP)
If the data link layer is reliable and has flow and error control,
Why do we need this at the transport layer, too?
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 (best-effort delivery),
we need to implement reliability at the transport layer.
To understand that error control at the data link layer does not guarantee error control at the transport layer
Error Control
Position of UDP, TCP, and SCTP in TCP/IP suite