Windows 2008 R2 forgets static IP configuration after reboot
Posted
by
Andrew
on Server Fault
See other posts from Server Fault
or by Andrew
Published on 2012-06-01T14:28:28Z
Indexed on
2014/06/07
3:32 UTC
Read the original article
Hit count: 480
I've got an issue where a Windows 2008 R2 Standard (SP1) server loses its static IP configuration upon a reboot. It's a sysprep'd image.
The following steps reproduces the problem:
- Using the SAC, set the IP using 'i'
- Use the Win32 EnableStatic() method to set an IP (and then SetGateways()) through PowerShell
- Reboot
The machine boots up with the following configuration:
Ethernet adapter Local Area Connection: Connection-specific DNS Suffix . : Link-local IPv6 Address . . . . . : [...] Autoconfiguration IPv4 Address. . : 169.254.152.31 (incorrect) Subnet Mask . . . . . . . . . . . : 255.255.0.0 (incorrect, was set to /24) Default Gateway . . . . . . . . . : 1.1.1.1 (correct)
Occasionally, the gateway is also incorrect (0.0.0.0)
The images have a script that runs 'netsh int ip reset' after sysprep finishes (before the reboot), so it appears that does not solve the issue. (the problem also happens without this step)
After the reboot, using 'i' on the SAC resolves the issue permanently. (But I'd like to know the root cause as having to run 'i' again isn't ideal)
© Server Fault or respective owner