Friday, May 2, 2008

TCP/IP, Subnet Mask and Default Gateway

TCP/IP, Subnet Mask and Default Gateway

What is TCP/IP for?
Computers have a common "language" that they use to talk to each other on the Net, which is called Transmission Control Protocol/Internet Protocol(TCP/IP). its ability to connect together different sizes networks and different type of networking operating system.

When you are connected directly to the Internet, your computer accesses a copy of the TCP/IP language, as does every other connected computer regardless of their particular operating system. When your computer utilizes this language it can communicate with other computers.

TCP/IP
In OSI Model, TCP at Transport Layer manages the assembling of a message or file into smaller "packets" that are transmitted over the Internet and received by a TCP layer on the receiving computer that reassembles the packets into the original message.

The Internet Protocol (IP) handles the address of each packet so that it gets to the right destination.

Three important components to a TCP/IP address: IP address, subnet mask, and default gateway.

IP Address
Ip Address looks like: 172.16.52.63

There are classes for IP address; Class A, B, C, D, E.
Class A, B, C allocated by the InterNIC (http://www.internic.net/(http://www.internic.net)), the organization that administers the Internet. each of which can be divided into smaller subnetworks by system administrators.

How to identify the class of an IP address?
• Class A
networks use a default subnet mask of 255.0.0.0 and have 0-127 as their first octet. The address 10.52.36.11 is a class A address. Its first octet is 10, which is between 1 and 126.

• Class B networks use a default subnet mask of 255.255.0.0 and have 128-191 as their first octet. The address 172.16.52.63 is a class B address. Its first octet is 172, which is between 128 and 191, inclusive.

• Class C networks use a default subnet mask of 255.255.255.0 and have 192-223 as their first octet. The address 192.168.123.132 is a class C address. Its first octet is 192, which is between 192 and 223.

• Class D & E for future use.

Subnet Mask
A subnet mask is used to divide an IP address into two parts.
One part identifies the host (computer), the other part identifies the network to which it belongs.

For example:
A subnet Mask: 255.255.0.0

The numbers that make up the subnet mask indicate which portion of the IP address is the network number and which portion is the computer number. The four numbers of the subnet mask correspond directly to the four numbers in the IP address.

if you had a computer with an IP address of 147.100.100.25 and a subnet mask of 255.255.0.0, the first two numbers in the subnet mask (both are 255) indicate that the first two numbers of the IP address are the network number. The second two numbers (both are 0) indicate that the second two numbers of the IP address are the computer number. Therefore, in the IP address 147.100.100.25, the 147.100 portion denotes which network the computer is located on, and the 100.25 portion represents a particular computer on that network.

Default Gateway
For computers on your network to talk to computers on another network, you need a default gateway. The default gateway is a computer to which other local computers send data that is destined for a non-local computer.

When computers attempt to communicate with other computers that are not local to the IP address range they belong to (the subnet they belong to), the local computers must send their data to the default gateway to be forwarded.

For Example:
Suppose you have a network with a node called Host 100 and a node called Host 200. Note that Host 100 is located on Network 1 and Host 200 is located on Network 2. Assume that Host 100 addresses and sends a packet to Host 200. After Host 100 checks its local routing tables and is unable to resolve the “path” to Host 200, it forwards the packet to the default gateway.




No comments: