Tuesday, July 14, 2009

testing a TCP/IP configuration

after configuring TCP/IP and restarting the computer, you should use ipconfig and ping command prompts tools to test the configuration and connections to other TCP/IP hosts and networks. such testing helps ensure that TCP/IP is functioning properly.

using ipconfig

you use the ipconfig tool to verify the TCP/IP configuration parameters on a host. this helps to determine whether the configuration is initialized or if a duplicate IP address exists. use the ipconfig tool with the /all switch to verify configuration information.

using ping

the ping tool is a diagnose tool that you can use to test TCP/IP configurations and diagnose connection failures. after you have verified the TCP/IP configuration, use the ping tool to determine whether a particular TCP/IP host is available and funtional. to test connectivity use the ping tool with the following syntax in command prompt:
  1. first go to the command prompt.
  2. then type ipconfig or ipconfig /all and press enter.
  3. then type ping 127.0.0.1 (loopback address) to check loopback working properly.
  4. then use ping ip address of the computer (eg: ping 192.168.0.10) to check NIC (network interface card) working properly.
  5. then use ping command to ip address of default gateway (router) to check connectivity to gateway.
  6. then use ping address of the remote host (this can be pc in the network or internet) to check network working properly.

using automatic private ip addressing (APIPA)

the windows xp professional implementation of TCP/IP supports automatic assignment of IP address for simple LAN -based network configurations. this addressing mechanism is an extension of dynamic IP address assignment for LAN adaptors, enabling configuration of IP address without using static IP address assignment or installing the DCHP service. automatic private IP addressing is enabled by default in windows xp professional so that home users and small business users can create a funtioning, single subnet, TCP/IP based network without having to configure the TCP/IP protocol manually or set up a DHCP server.

the process for the automatic private IP addressing feature
  • windows xp professional TCP/IP attempts to find a DHCP server on the attached network to obtain a dynamically assigned IP adrress.
  • in the absence of a DHCP server during startup (for example, if the server is down for maintanance or repairs) the client cannot obtain an IP address.
  • automatic private IP addressing generates an IP address in the form of 169.254.x.y (where x.y is the client,s unique identifier) and a subnet mask of 255.255.0.0 .

obtaining an ip address automatically

if a server running the DHCP service is available on the network, it can automatically assign TCP/IP configuration information to the DCHP client, you can configure any clients running windows xp professional, windows 95, and windows 98 to obtain TCP/IP configuration information automatically from the DHCP service. this can simplify administration and ensure correct configuration information.

you can use the DHCP service to provide clients with TCP/IP configuration information automatically. however you must configure a computer as a DHCP client before it can interact with the DHCP service.

using a static IP address

by default client computers, for example those running windows xp professional, windows 2000, windows ME, windows NT, microsoft windows 98, or microsoft windows 95 obtain TCP/IP configuration information automatically from the DHCP service. however even in DHCP enabled environment you should assign a static IP address to selected network computers. for example, the computer running DHCP service cannot be a DHCP client, so it must have a static IP address. if the DHCP service is not available you can also configure TCP/IP to use static IP address. for each network adaptor card that uses TCP/IP in a computer, you can configure an IP address, subnet mask and default gateway.

understanding ip addresses

each IP address consists of a network ID and a host ID. the network ID, also known as the network address, identifies the systems that are located on the same physical network. all computers in the same physical network must have the same network ID, and the network ID must be unique to the internetwork. the host ID, also known as the host address, identifies each TCP/IP host within a network.

IP addresses are logical 32-bit numbers that are broken down into four 8 bit fields known as octets. microsoft TCP/IP supports class A, B and C addresses. the class addresses define which bits are used for network ID and which bits are used for the host ID.

Class A

the first network ID is 1.0.0.0 and the last is 126.0.0.0 , this allows for 126 networks and 16,777,214 hosts per network. the class A adress 127.x.x.x is reserved for loopback testing and interprocess communications on the local computer. for class A addresses, the network ID is laways the first octet in the address and the host ID is the last three octets.

Class B

the first network ID is 128.0.0.0 and the last is 191.255.0.0 , this allows for 16,384 networks and 65,534 hosts per network. for class B addresses the network ID is always the first two octets in the address and host ID is the last two octets.

Class C

the first network ID is 192.0.0.0 and the last is 223.255.255.0 , this allows for 2,097,152 networks and 254 hosts per network. for class C addresses, the network ID is always the first three octets in the address and the host ID is the last octet.

options for configuring a static TCP/IP address

IP address - a logical 32-bit address that identifies a TCP/IP host. each network adpter card in a computer running TCP/IP require a unique IP address, such as 192.168.0.108 , each address has two parts: a network ID, which identifies all hosts on the same physical network, and a host ID which identifies a host on the network. in this example the network ID is 192.168.0 and the host ID is 108.

subnet mask - subnets divide a large network into multiple physical networks connected with routers.a subnet mask blocks out part of the IP address so that TCP/IP can distinguish the network ID from the host ID. when TCP/IP hosts try to communicate, the subnet mask determine whether the destination host is on a local or remote network. to communicate on a local network, computers must have the same subnet mask.

default gateway - the intermediate device on a local network that stores network ID,s of other networks in the enterprise or internet. to communicate with a host on another network, configure an IP address for the default gateway. TCP/IP sends packets for remote networks to the default gateway (if no other route is configured) which then forwards the packets to other gateways until the packet is delivered to a gateway connected to specified destination.