One warning before anything else, because guides rarely mention it and the consequence is immediate.
Never run ipconfig /release on a machine you are connected to remotely. The command drops the machine's address, your remote session dies at that instant, and the renew command you were about to type never executes. You are left with a machine holding no address, no way to reach it, and a walk to wherever it physically sits.
If you must do this remotely, combine both commands into a single line so the release and the renew execute together:
ipconfig /release && ipconfig /renew
Your session will still drop momentarily, and the machine will recover on its own. With that established, here is what these commands actually do and when they help.
What They Actually Do
These are not vague refresh operations. Each sends a specific message defined by the DHCP protocol.
ipconfig /release sends a DHCP Release message to the server that issued the current lease. The server marks that address as available again, and the client discards its configuration entirely — address, mask, gateway, and DNS servers all go.
ipconfig /renew requests configuration. If the client still holds a valid lease, it sends a Request to the original server asking to extend it. If it has no lease — because you just released, or because it never had one — it broadcasts a Discover message and goes through the full four-step process of obtaining a new address.
Both require administrator rights on modern Windows.
When Renew Alone Is Enough
Most of the time, you do not need to release first. Running renew by itself is faster, safer, and sufficient for the common cases:
- The machine has an address beginning 169.254, meaning no DHCP server answered earlier. Renewing asks again, and if the server is now available, the machine gets a proper address.
- Configuration changed on the server — new DNS servers, a changed gateway, a modified domain — and you want the client to pick it up without waiting for the lease to expire naturally.
- A DHCP reservation was just created for this device and you want it to take effect now.
- The machine was moved between networks and is holding stale configuration from the previous one.
- The network was down when the machine started and has since recovered.
Renew is non-destructive. If it fails, the machine keeps whatever it had, which is why it is the safer first attempt.
When You Need Release First
Releasing is necessary in a narrower set of circumstances:
- The machine holds an address from the wrong network, usually after moving between sites, and renew keeps extending the wrong lease.
- A duplicate address conflict exists, where
ipconfig /allshows the address marked as Duplicate rather than Preferred. The machine needs to abandon it entirely. - You want to free the address in the DHCP pool immediately — relevant when a scope is running low.
- A rogue DHCP server issued the configuration and you have since removed it. Renewing may go back to the same source; releasing forces a fresh discovery.
- Testing a reservation, where you need the client to request a new address rather than extend an existing one.
When They Will Not Help At All
Equally important, because running them reflexively wastes time:
- The address is configured statically. These commands operate on DHCP. On a manually configured adapter they do nothing whatsoever.
- The problem is DNS. If the machine has a valid address and names do not resolve, renewing changes nothing relevant.
- The cable is unplugged. No physical link means no DHCP conversation. Fix the link first.
- The problem is routing or firewall policy. A perfectly valid address will still fail to reach a destination that is blocked.
- The DHCP server itself is down. Releasing in this situation makes things worse — you have discarded a working configuration in exchange for nothing.
That last point is worth emphasising. A machine with an expired-but-still-functional lease is better off than one with no address. If you suspect the server is unavailable, do not release.
Reading the Result
After running renew, check what happened:
ipconfig /all
What you should see: a sensible address in the expected range, marked as Preferred, with a mask, a gateway, a DHCP server address, and a fresh lease-obtained timestamp.
What indicates failure:
- An address beginning 169.254 means no server responded. The DHCP conversation failed.
- "Media disconnected" means there is no physical link, and DHCP never had a chance.
- The DHCP server field showing an unexpected address means something other than your server answered — investigate for a rogue device.
- The same address as before is normal and not a failure. DHCP servers deliberately reissue the same address to the same device where possible.
That last point confuses people regularly. Getting the same address back does not mean the command failed.
Targeting a Specific Adapter
On a machine with several adapters, running these commands affects all of them, which is rarely what you want.
Name the adapter explicitly:
ipconfig /renew "Ethernet"
Wildcards work, which helps when names are long:
ipconfig /renew Eth*
Use the adapter name as Windows displays it in ncpa.cpl. Getting the name wrong produces a silent no-op rather than an error, which is worth knowing when nothing appears to happen.
The IPv6 Variants
Separate commands handle IPv6:
ipconfig /release6ipconfig /renew6
Relevant only on networks running IPv6 with DHCPv6. On networks using stateless autoconfiguration, where devices build their own addresses from a router advertisement, these commands have nothing to operate on.
If you are troubleshooting on a dual-stack network, remember that fixing IPv4 addressing may not resolve the problem if traffic is preferring IPv6.
What to Do If Renew Fails
Working through in order:
- Confirm the physical link. Check the link lights and confirm
ipconfig /alldoes not report media disconnected. - Try the other medium. If the machine has both wired and wireless, test whether the other one obtains an address. This separates the machine from the network immediately.
- Test another device on the same port. If it also fails, the problem is the network, not this machine.
- Check whether the port is in the right VLAN, since a VLAN with no DHCP service produces exactly this symptom.
- Verify the DHCP server is running and its scope has available addresses.
- Check the relay configuration on the gateway, if the server sits on a different segment.
- Assign a static address temporarily to confirm the rest of the path works. If it does, the problem is specifically DHCP.
The Full Reset Sequence
When renew alone does not resolve it and you suspect the machine's configuration is corrupted, run this from an administrator prompt:
ipconfig /releaseipconfig /flushdnsnetsh winsock resetnetsh int ip resetipconfig /renew
Then restart the machine. The two netsh commands do not take full effect until you do.
Use this deliberately rather than routinely. It resets configuration that some VPN clients and security products depend on, and occasionally one needs reinstalling afterwards.
Why You Rarely Need These Commands
A point worth making, because it reframes when reaching for them is appropriate: DHCP renews itself automatically, and the process is more robust than most people realise.
A client does not wait for its lease to expire. It attempts renewal at 50 percent of the lease duration, contacting the issuing server directly. If that fails, it tries again at 87.5 percent, this time broadcasting to any available server. Only at 100 percent does it give up and release the address.
With an eight-day lease, a machine begins trying to renew on day four and keeps trying for another three and a half days before anything breaks. A DHCP server that goes down at midday and returns the following morning affects nobody.
Two consequences follow:
- Addressing problems are rarely caused by renewal failing quietly. If a machine has a valid address, the renewal mechanism is almost certainly working.
- Running these commands during a DHCP outage is actively harmful, because you discard a working lease that would have survived until the server returned.
The practical rule: use them when the configuration is wrong, not when the network is down. Those look similar from a support desk and require opposite responses.
Other Platforms
The equivalents, since mixed environments are normal:
- macOS:
sudo ipconfig set en0 DHCPforces a renewal on the named interface. The Network settings panel also offers a Renew DHCP Lease button. - Linux with dhclient:
sudo dhclient -rreleases andsudo dhclientrequests. - Linux with NetworkManager:
sudo nmcli con down "connection-name"followed bysudo nmcli con up "connection-name".
Without the Command Line
For users who need to do this themselves, disabling and re-enabling the adapter in ncpa.cpl achieves a similar result — the adapter drops its configuration and requests a new one when it comes back up.
It is less precise than the commands and considerably easier to explain over the phone, which occasionally matters more.
The Principle
These commands solve one specific class of problem: the machine's addressing is wrong, missing, or stale, and DHCP can supply a correct one.
They are not a general repair. Running them against a DNS problem, a routing problem, or a physical fault changes nothing — and running release without renew on a remote machine creates a new problem considerably worse than the original.
Check ipconfig /all first, confirm that addressing is genuinely the issue, and then use ipconfig /release and /renew deliberately rather than as a reflex.

0 تعليقات