TCP/IP is a protocol suite, which consists of protocols for all four layers. This suite is used for intranets as well as for Internet. 70% of all networks use TCP/IP. This protocol provides a reliable stream delivery and virtual connection service to the applications. The protocol ensures error-free transmission. TCP performs packetizing-large messages are broken up into smaller units called packets. Each packet contains the source and destination port identifier. A port is a logical entity that identifies an application. The web server port is 80. FTP server port is 21, TELNET port is 23 and SMTP port is 25. The packet also contains its sequence number and error checking information. The source and destination addresses are also included in the packet.
The address part needs some explanation. Each computer has some device such as network card or modern through which computer is connected to the network. This device has an address. For instance, the Ethernet card addresses are 6 bytes long. The address is part of the hardware and cannot be changed. This address is unique in the world. The network administrator assigns a 4 byte address to each computer on the network. This address is known as IP address. This address has to be unique on the network. The way this uniqueness is ensured is quite interesting. A computer on the LAN is assigned an. address by the system administrator. These addresses are 4 numbers separated by a dot (.), each number is between 1 and 254.
The intranet addresses are usually 172.x.x.x. The system administrator maintains a table of assigned addresses and can easily ensure the uniqueness. A computer on the Internet is assigned an address by the Internet Network Information Center (InterNIC) who again maintains a, table and can ensure uniqueness. The Internet service providers can get a block of addresses from InterNIC and assign them to individuals or organizations.
An address can be one of the following types:
Type A: The first byte is fixed by the NIC. The first bit of this byte is 0 for all type. A addresses. The first byte can have value between 1 and 127. The remaining 24 bits are used to identify the host on the network. An organization that has obtained a type A address may connect over 16 million computers to the Internet. Type A address is no more available.
Type B: The first two bytes are fixed by the NIC. The first two bits of the first byte are 10 for all type B addresses. The first byte can have value between 128 and 191 The remaining 16 bits are used to identify the host on the network. An organization that has obtained a type B address may connect over 65000 computers to the Internet. Almost 80% type B addresses have already been allocated.
Type C: The first three bytes are fixed by the NIC. The first three bits of the first byte are 110 for all type C addresses. The first byte can have value between 192 and 233. The remaining 8 bits are used to identify the host on the network. An organization that has obtained a type C address may connect 254 computers to the Internet. Almost 30% type C addresses have already been allocated. There are Type D and Type E addresses also which are not for commercial use. An organization has the freedom to divide its computers into various clusters and each cluster forms sub-network, referred to as subnet. The address of each computer on a subnet has same first three digits. The subnet mask identifies the subnet part of the address. The subnets are connected to each other by a gateway.
The IP address may be static or may be dynamic. A static address is assigned to the. computers that are permanent members of the network. The computers that connect to the network through a modem are usually assigned IP address dynamically. Dynamic Host Configuration Protocol (DHCP) is part of the TCP/IP suite for dynamic addressing. A client can be. assigned all IP address dynamically by DHCP server. It is not so easy to remember 4 decimal numbers for each computer that one might like to communicate with. The name that a human being can remember easily is assigned to each server.
Domain Name Service protocol (DNS): translates server address to IP address. There are name servers, which maintain a special database of IP addresses and application layer addresses. There are thousands of name servers across the globe. If a computer does not know the IP address for an application layer address, it sends a request to name server. Other computers can reach a computer only if its address is a part of the database of at least one name server. This is the reason no one can just assign an address to its computer and expect to be found without the knowledge of InterNIC. Each computer can update its local database as more and more addresses from the name servers are learnt.
The ARP is used for converting an IP address to the hardware address. The protocol is based on broadcast; the computer trying to send a message to a particular IP address broadcasts a message asking for its hardware address. The computer with requested IP address responds back. The requesting computer also maintains a database of IP addresses and corresponding hardware addresses.
To send a message to a computer on another network, the sender needs to know a route to the destination. In static routing, the network administrator develops a routing table. In dynamic routing, the initial routing table is created by the system administrator as in case of static routing. The system then updates its routing table depending upon the situation of the network. A message is broken up into packets. All the packets may travel independently on possibly different routes. This type of routing is known as connectionless routing. If all packets of a message are forced to travel same path, then a virtual circuit is setup. This type of routing is known as connection-oriented routing.