Tutorials › Windows Server

Troubleshoot clients with no IP address: when the DHCP server stops

Your clients have no internet, and ipconfig shows an address starting 169.254. Nine times out of ten, the DHCP server isn't answering. This tutorial walks through a real lab fault, a domain controller whose DHCP Server service had stopped, and fixes it step by step, in the order you'd check it at work.

The lab

  • DC01: Windows Server domain controller, also running DNS and DHCP.
  • Two client VMs on the same virtual network, set to get their IP address automatically.
  • The symptom: both clients lose internet and can't reach the domain.

Part 1: Check the client

  1. On a client, right-click Start and open Terminal or Command Prompt.
  2. Run:
    ipconfig /all
    Find your network adapter and look at four lines: DHCP Enabled, IPv4 Address, Default Gateway and DHCP Server.
  3. Read the result:
    • IPv4 address starts 169.254: the PC asked for an address, nobody answered, so Windows gave itself one. Microsoft calls this Automatic Private IP Addressing (APIPA). Go to Part 2.
    • DHCP Enabled: No: the PC has a static address, so DHCP isn't involved. Check the static settings instead.
    • A normal address, gateway and DHCP server: DHCP is working. The fault is somewhere else, such as DNS or the gateway.
  4. Check the second client too. If both have 169.254 addresses, the problem is almost certainly the server or the network, not the PCs.
  5. Quick client checks before you move on: the virtual network adapter is connected, the VM is on the right virtual switch, and the adapter is enabled in Settings → Network & internet.

Part 2: Check the DHCP server

  1. Sign in to DC01.
  2. Right-click Start and select Terminal (Admin) or Windows PowerShell (Admin).
  3. Check the DHCP Server service:
    Get-Service DHCPServer
    Status should say Running. In our lab it said Stopped. That's the fault.
  4. Check how the service is set to start:
    Get-Service DHCPServer | Select-Object Name, Status, StartType
    If StartType is Disabled or Manual, it won't come back after a reboot.
  5. Set it to start automatically, then start it:
    Set-Service DHCPServer -StartupType Automatic
    Start-Service DHCPServer
    If it was already running but misbehaving, use Restart-Service DHCPServer instead.
  6. Check again:
    Get-Service DHCPServer
    It should now say Running.
  7. Find out why it stopped. Open Event Viewer (Server Manager → Tools → Event Viewer) and look at:
    • Windows Logs → System, for Service Control Manager events about the DHCP Server service
    • Applications and Services Logs → Microsoft → Windows → DHCP-Server
    If someone stopped it by hand, that's a process problem. If it keeps crashing, the events will tell you where to look next.

Part 3: Check the DHCP setup, not just the service

A running service isn't enough. Microsoft's DHCP checklist also covers these:

  1. Open Server Manager → Tools → DHCP and expand the server.
  2. Authorised: if IPv4 shows a red down arrow, right-click the server name, choose Authorize and press F5. In a domain, an unauthorised server won't hand out addresses.
  3. Scope active: expand IPv4. If the scope has a red arrow, right-click it and choose Activate.
  4. Addresses free: check the scope isn't full. In PowerShell:
    Get-DhcpServerv4Scope
    Get-DhcpServerv4ScopeStatistics
    A scope at or near 100% in use can't give out new addresses.
  5. Bound to the right network: the server must listen on an address inside the scope's subnet:
    Get-DhcpServerv4Binding
  6. Only one DHCP server: make sure the router or your lab's virtual network isn't also handing out addresses.

Part 4: Get the clients a new address

ipconfig /release drops the PC's network connection straight away. If you're connected to the client remotely (RDP or a remote support tool), you'll lose the session and may not get it back. Run release and renew on the console, or just run ipconfig /renew on its own.
  1. On each client, open Terminal or Command Prompt.
  2. Run:
    ipconfig /release
    ipconfig /renew
    /renew can take up to a minute. If it times out, go back to Part 2 and Part 3.

Check it worked

  1. On each client, run ipconfig /all and confirm:
    • IPv4 Address is inside your scope's range, not 169.254
    • DHCP Server shows DC01's IP address
    • Default Gateway and DNS Servers are what you set in the scope options
  2. Test each step of the path:
    ping <DC01 IP address>
    nslookup <your domain name>
    ping 8.8.8.8
    nslookup bbc.co.uk
    If the DC ping works but internet doesn't, look at the gateway. If ping 8.8.8.8 works but names don't resolve, look at DNS.
  3. On DC01, open the DHCP console, expand the scope and select Address Leases. Both clients should be listed.
  4. Restart DC01 when you can and run Get-Service DHCPServer again to prove it comes back on its own.

The order to remember

Client first (ipconfig /all, look for 169.254) → is it one PC or all of them? → DHCP Server service → authorised, scope active, addresses free → release and renew → check the lease, gateway and DNS → find out why it stopped.

Sources

← All tutorials