Personal tools
You are here: Home Classes Fall 2004 - Spring 2005 CS 342 The Transport Layer
Navigation
Log in


Forgot your password?
« July 2008 »
Su Mo Tu We Th Fr Sa
12345
6789101112
13141516171819
20212223242526
2728293031
 
Document Actions

The Transport Layer

by admin last modified 2005-05-12 17:54

The Transport Layer

Chapter 6 in Tanenbaum

Objective:  Provide end-to-end communication for applications
  • In particular, the transport layer must provide delivery to a process running on a host, not just to the host machine.
  • The transport layer must provide an application interface, such as the socket interface in Unix and Java
  • The service may or may not be reliable (TCP vs UDP)

A message routed from one host to another is handled by network, data link, and physical layers on each router; but by transport layer only on each end.

From the transport layer's point of view, the entire network acts like a communication channel between hosts that provides packet delivery service.

From this point of view, the transport layer's job is to provide a standard interface to applications, hiding details of the network.

The transport layer is to the network layer as the data link layer is to the physical layer, and it carries out some of the same functions, such as error handling and flow control.

In general, a transport layer may provide some or all of the following services:
  1. process-to-process communication
  2. error checking
  3. reliable data transfer
  4. congestion control
TCP does all of these; UDP only the first two.

Process-to-process communication

  • Accomplished by both UDP and TCP using port numbers
  • Each transport layer segment TPDU (transport protocol data unit) contains source and destination port numbers
  • IP is host-to-host.  IP packets have source and destination IP addresses
  • Communication is really socket-to-socket (not process-to-process), because one socket can be shared by several processes

UDP version

  • Each socket is bound to a port number
  • When an incoming packet arrives, it is enqueued on that socket's queue

TCP version

  • All sockets originating from the same listening socket use the same port number
  • When a socket is created, it is associated (within the kernel) with its port number and the IP address and port number of the socket at the other end of the connection
  • When an incoming packet arrives, its destination port number, source IP address, and source port number are used to enqueue its contents on the appropriate destination socket.

UDP -- User Datagram Protocol




Segment structure

  1. source port number
  2. destination port number
  3. length
  4. checksum
  5. payload
checksum = the sum (mod 216) of all 16-bit words in the message

UDP adds only two services to the IP layer:
  • delivery to processes/sockets/ports
  • checksum
(IP address, port number) uniquely identifies endpoint
TSAP - Transport Service Access Point


TCP -- Transport Control Protocol

Characteristics
  • connection-oriented
  • reliable
  • full duplex
  • point to point (no multicasting)

How can reliability be achieved in the face of
  • garbled messages
  • lost messages
  • slow messages
  • machine failure/reboot

Things to look at:
  • TCP segment format
  • Connection setup and tear down
  • Retransmission scheme (think "sliding window")
  • Congestion control




 

Powered by Plone CMS, the Open Source Content Management System

This site conforms to the following standards: