Site hosted by Angelfire.com: Build your free website today!

TCP/IP - Explained





Transmission Control Protocol (TCP/IP) is a stack or collection of various protocols. A protocol is basically the commands or instructions that two computers within a local network or the Internet use to exchange data or information and resources. TCP/IP was developed around the time of the ARPAnet.It is also known as a protocol suite. It consistes of various protocols, but as TCP and the IP are the most well known of the suite of protocols, the entire family is called the TCP/IP suite. The TCP/IP suite is a stacked suite with various layers. Each layer looks after one aspect of data transfer. Data is transferred from one layer to another. The entire TCP/IP suite can be broken down into the following layers:

Link Layer
Network Layer
Transport Layer
Application Layer
Physical Layer

Data travels from the Link layer down to the Physical layer at the source. At the destination, it travels from the physical layer to the Link layer.

The TCP/IP suite not only helps to transfer data, but also has to correct various problems that might occur during data transfer. There are basically two types of common errors that occur during the process of data transfer. They are:

  1. Data Corruption: The data reaches the destination after getting corrupted.
  2. Data Loss: The entire number of packets that constitute the data to be transferred does not reach the destination at all.

Checksums

A checksum is a value (normally 16-bit) that is formed by summing up the binary data in the used program for a given data block. The program being used is responsible for the calculation of the checksum value. The data being sent by the program sends this calculated checksum value, along with the data packets, to the destination. When the program at the destination recieves the data packets, it re-calculates the checksum value. If the checksum value calculated by the destination program matches with the value attached to the data packets by the source program, then the data transfer is said to be valid and error free. Checksum is calculated by adding up all the octets in a datagram.

Packet Sequencing

All data being transferred on the net is broken down into packets at the source and joined together at the destination. The data is broken down into packets in a particular at the source. For example, the first byte has the first sequence number, the second byte has the second sequence number, and so on. These packets are free to travel independently on the Net, so sometimes, when the data packets reache the destination, they arrive out of sequence. This means that the packet that had the first sequence number attached to it does not reach the destination first. Sequencing defines the order in which the host recieves the data packets or messages. The application or the layer running at the destination automatically builds up the data from the sequence number in each packet.