Troubleshooting Tools and Strategies

IPConfig is a command-line tool that displays the current configuration of the installed IP stack on a networked computer using TCP/IP.

Run IPConfig from a command prompt rather than from Windows Explorer to see the resulting display.

IPConfig Syntax

The command-line syntax for IPConfig is as follows:

ipconfig [/?|/all|/release [adapter]|/renew [adapter] |/flushdns|/registerdns|/showclassid adapter |/setclassid adapter [classidtoset]]

adapter Full name or pattern with '*' and '?' to 'match', * matches

any character, ? matches one character.

The default is to display only the IP address, subnet mask and default gateway for each adapter bound to TCP/IP.

For /release and /renew, if no adapter name is specified, then the IP address leases for all adapters bound to TCP/IP will be released or renewed.

For SetClassID, if no class ID is specified, then the ClassID is removed.

IPConfig Switches

Table 31.24 lists the IPConfig command-line switches.

Table 31.24 IPConfig Switches

Switch

Effect

/all

Produces a detailed configuration report for all interfaces.

/release <adapter >

Releases the IP address for a specified adapter. If no adapter name is specified, releases the DHCP leases for all adapters bound to TCP/IP.

/renew <adapter >

Renews the IP address for the specified adapter. If no adapter name is specified, renews the DHCP leases for all adapters bound to TCP/IP.

/flushdns

Removes all entries from the DNS Resolver Cache.

/registerdns

Refreshes all DHCP leases and reregisters DNS names.

/displaydns

Displays the contents of the DNS Resolver Cache.

/showclassid adapter

Displays all the DHCP class IDs allowed for the specified adapter.

/setclassid adapter

Modifies the DHCP class ID for the specified adapter.

/?

Displays this list.

caution-icon

Caution

It is recommended that only a network administrator or support personnel use many of the advanced features of IPConfig. Using these commands incorrectly can cause problems with the client system's connection to the server.

\

Run IPConfig to check the status of a computer's TCP/IP configuration. When used with the /all switch, it displays a detailed configuration report for all interfaces, including any configured WAN miniports (typically used for remote access or virtual private network [VPN] connections). The following is a sample report:

Windows 2000 IP Configuration

Host Name . . . . . . . . . . . . : TESTPC1

Primary Domain Name . . . . . . . : reskit.com

Node Type . . . . . . . . . . . . : Hybrid

IP Routing Enabled. . . . . . . . : No

WINS Proxy Enabled. . . . . . . . : No

DNS Suffix Search List. . . . . . : ntcorpdc1.reskit.com

dns.reskit.com

reskit.com

Ethernet adapter Local Area Connection:

Connection-specific DNS Suffix . : dns.reskit.com

Description . . . . . . . . . . . : Acme XL 10/100Mb Ethernet NIC

Physical Address. . . . . . . . . : 00-CC-44-79-C3-AA

DHCP Enabled. . . . . . . . . . . : Yes

Autoconfiguration Enabled . . . . : Yes

IP Address. . . . . . . . . . . . : 172.16.245.111

Subnet Mask . . . . . . . . . . . : 255.255.248.0

Default Gateway . . . . . . . . . : 172.16.240.1

DHCP Server . . . . . . . . . . . : 172.16.248.8

DNS Servers . . . . . . . . . . . : 172.16.55.85

172.16.55.134

172.16.55.54

Primary WINS Server . . . . . . . : 172.16.248.10

Secondary WINS Server . . . . . . : 172.16.248.9

Lease Obtained. . . . . . . . . . : Friday, March 05, 1999 2:21:40 PM

Lease Expires . . . . . . . . . . : Sunday, March 07, 1999 2:21:40 PM