Sub topic 3
Checking your configuration with ipconfig
This chapter assumes you know what an IP address is, can open a Command Prompt or terminal, and know that devices on a network reach each other through routers. Before you test connectivity, you need to know how your own computer is configured. On Windows, ipconfig shows that configuration.
What ipconfig tells you
ipconfig reads the network settings of the local machine and prints them. It does not send anything across the network. It reports what the computer believes about its own setup. A correct-looking configuration does not prove the network works, but a wrong one explains many faults before you run a single test.
Run it with no options for a summary:
ipconfig
ipconfig /allThe first command prints a short block for each network adapter. The second adds the MAC address, DHCP status, and DNS servers.
Reading the basic output
A typical block for a wired or Wi-Fi adapter looks like this:
Ethernet adapter Ethernet:
Connection-specific DNS Suffix . : home.example
IPv4 Address. . . . . . . . . . . : 192.168.1.42
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.1.1Each field answers one question.
| Field | Meaning | What to check |
|---|---|---|
| IPv4 Address | The address of this interface on the local network. | It should fall in the range your network uses. |
| Subnet Mask | Which part of the address identifies the local network. | It should match the other devices on the same network. |
| Default Gateway | The router the computer sends traffic to when the destination is not local. | It should be present and in the same subnet as your address. |
Two relationships matter most.
- Local or remote. The computer applies the subnet mask to decide whether a destination is on the same network. With
192.168.1.42and255.255.255.0, any address from192.168.1.1to192.168.1.254is local. The computer reaches those directly. Everything else goes to the default gateway. - Gateway must be local. The gateway has to be inside your own subnet, because your computer must reach it directly. A gateway of
10.0.0.1with an address of192.168.1.42and a/24mask cannot work.
If the Default Gateway line is empty, the computer has no route off its local network. You can still reach neighbors, but not the internet.
Adapters you will see
A modern machine often lists more adapters than you expect. Each gets its own block.
- Ethernet adapter and Wireless LAN adapter Wi-Fi are the physical interfaces.
- Local Area Connection\* entries are virtual adapters, for example Wi-Fi Direct or hotspot features.
- vEthernet entries usually come from virtual machines or containers.
- VPN adapters appear when a VPN client is installed.
Adapters that are disconnected show "Media disconnected". Skip them. Look at the adapter that carries your traffic, usually the one with a default gateway. If two adapters both have a gateway, the system picks one based on route metrics, which is a common cause of confusing behavior with VPNs.
Reading ipconfig /all
ipconfig /all adds the details you need to diagnose address assignment and name resolution.
Ethernet adapter Ethernet:
Description . . . . . . . . . . . : Intel(R) Ethernet Connection
Physical Address. . . . . . . . . : 00-1A-2B-3C-4D-5E
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
IPv4 Address. . . . . . . . . . . : 192.168.1.42(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Lease Obtained. . . . . . . . . . : Friday, November 27, 2026 8:00:12 AM
Lease Expires . . . . . . . . . . : Saturday, November 28, 2026 8:00:12 AM
Default Gateway . . . . . . . . . : 192.168.1.1
DHCP Server . . . . . . . . . . . : 192.168.1.1
DNS Servers . . . . . . . . . . . : 192.168.1.1
8.8.8.8The extra fields are:
- Physical Address is the MAC address, the hardware identifier used on the local link.
- DHCP Enabled says whether the address came from a DHCP server (Dynamic Host Configuration Protocol, the service that hands out addresses automatically) or was typed in by hand.
- Lease Obtained and Lease Expires show how long the DHCP assignment lasts.
- DHCP Server is the machine that granted the lease.
- DNS Servers are the servers your computer asks to turn names into IP addresses. The first one listed is tried first.
Recognizing a bad configuration
Some outputs point straight at the cause.
| What you see | What it means |
|---|---|
| Address starts with `169.254.` | DHCP failed. Windows gave itself an automatic private address (APIPA). The computer can talk only to other `169.254.` devices on the same link. |
| "Media disconnected" on the adapter you expect to use | No link. Check the cable, Wi-Fi connection, or adapter state. |
| No Default Gateway | Local traffic works, but nothing outside the subnet does. |
| Address in a different subnet from the gateway | A static setting is wrong, or the machine is on the wrong network. |
| DNS Servers empty or unreachable | You can reach IP addresses but names fail to resolve. |
| Address matches another device | An address conflict. Windows may show a conflict message and mark the address as Duplicate. |
Renewing the lease and flushing the DNS cache
Three further ipconfig options change state instead of only displaying it.
ipconfig /release
ipconfig /renew
ipconfig /flushdnsipconfig /releasegives up the current DHCP lease. The adapter then has no usable address until you renew.ipconfig /renewasks the DHCP server for a lease again. You often get the same address back, but not always.ipconfig /flushdnsclears the local DNS resolver cache. Use it when a name resolves to an old address, for example after a site moved.
Running /release and /renew over a remote session such as Remote Desktop can cut your own connection. Do this at the machine, or be ready to reconnect.
These options affect adapters that use DHCP. If an address is static, /release and /renew have nothing to do.
Targeting one adapter
On a machine with several adapters, you can name one. The name goes in quotes if it contains spaces, and wildcards are allowed.
ipconfig /renew "Wi-Fi"
ipconfig /release "Ethernet*"This avoids dropping a VPN or virtual adapter by accident.
The Linux equivalent
Linux has no ipconfig. The ip command shows the same information.
ip addr show
ip route showip addr show lists each interface with its addresses and masks (written as a prefix such as /24). ip route show lists routes, and the line beginning default via gives the default gateway. A later chapter covers the Linux and macOS commands in full.
Using ipconfig in a troubleshooting sequence
ipconfig is the first step because it is cheap and rules out whole classes of fault.
- Run
ipconfig /all. - Confirm the adapter you expect is connected and has an address that is not
169.254.x.x. - Confirm the mask and gateway fit your address.
- Note the DNS servers and the gateway address. You will use the gateway in the next chapters, as a
pingtarget.
The diagram shows how the result routes your next step.
Common mistakes
- Reading the wrong adapter. Virtual and VPN adapters clutter the output. Find the adapter with the gateway.
- Trusting a stale lease. The display shows what the computer holds, not whether the DHCP server still agrees. If in doubt, renew.
- Assuming a correct configuration means a working network.
ipconfigcannot see a dead router or a cut cable upstream. That is whatpingis for. - Confusing the gateway with the DNS server. On home networks they are often the same device, but they are separate roles. One routes packets and the other resolves names.
Exercise
ipconfig shows IPv4 Address 192.168.1.42, Subnet Mask 255.255.255.0, and Default Gateway 192.168.0.1. Can this computer reach the internet? Explain, and say what to check first.
Show answer
No. With a /24 mask, the local network is 192.168.1.0 to 192.168.1.255, and the gateway 192.168.0.1 is outside it. The computer cannot reach the gateway directly, so it cannot send off-network traffic. Check whether the static settings were typed wrongly or whether the computer is on the wrong network, and correct the address or gateway so both sit in the same subnet.
Exercise
A laptop shows IPv4 Address 169.254.18.7 on its Wi-Fi adapter. Which ipconfig command would you try after checking the connection, and what would you expect if the DHCP server is reachable again?
Show answer
Run ipconfig /renew (optionally ipconfig /release first). If the DHCP server answers, the adapter receives a normal lease with an address in the network's range, a subnet mask, a default gateway, and DNS servers, and the 169.254 address disappears.