IPCONFIG.EXE


So how do you even know what your IP address is? How can you tell that your computer is using an APIPA address in the first place?

The answer to both of these questions is Ipconfig.exe. Ipconfig is an invaluable command-line utility that displays IP configuration information. When run without any switchesin other words, just by typing IPCONFIG at the command promptit shows the assigned IP address, subnet mask, and default gateway. (For instructions on how to use the command line, refer back to Chapter 6, "The Command Line and Other Advanced Techniques.")

Ipconfig can be wielded to display additional information as well, and can even be used as a configuration tool, instructing your computer to release and renew its currently assigned address. Table 9-1 explains a few of the more helpful Ipconfig switches.

Table 9-1. Helpful Ipconfig Switches

Switch

What It Does

/all

Shows information about your IP connection, including which DNS servers are used and whether the address is dynamic or static. It also displays the host name.

/release

Releases the IP address that has been assigned through DHCP.

/renew

Renews a DHCP address.

/registerdns

Re-registers the computer name with the configured DNS server. This can be useful for troubleshooting name resolution problems.

/flushdns

Clears the contents of the DNS resolver cache, an area of memory that stores recently resolved names to prevent repeat trips to the DNS server. However, these entries can be incorrect, and this command will clear out any incorrect entries made by an improperly configured DNS server.


For example, the output of IPCONFIG /ALL displays a reading such as the one shown in Figure 9-6.

Figure 9-6. Results of Ipconfig.


I've drawn special attention to the part of the output that lets me know that my system is a DHCP client and that it will use APIPA in the event that a DHCP server cannot be reached.



Spring Into Windows XP Service Pack 2
Spring Into Windows XP Service Pack 2
ISBN: 013167983X
EAN: 2147483647
Year: 2004
Pages: 275
Authors: Brian Culp

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net