Force Windows DHCP to Update DNS for All Current Leases
Is there are way to force Windows 2008R2 DHCP Server to update all DNS entries for all current leases?
(Guess the server-side equivalent of ipconfig /registerdns
)
We had a configuration issue with our dynamic DNS and DNS is badly out of sync with the current leases. It's taking days to catch up now that we've fixed (I think) the original issue.
Solution 1:
I'm afraid that you're going to have to approach this from the client end. Changing the timeouts is only going to help clients the next time they check in, which is usually after half the existing lease time, or sometimes during boot. You can approach this by manually forcing the clients to check in. You might be able to do this by tweaking some group policy settings, or by running a script to bulk "ipconfig /registerdns" on a bunch of clients.
If you insist on doing this from the server end of things, it should be possible to write a custom program to read the entries from a DHCP lease export, and register the addresses, but be sure to run it as the same account that DHCP uses for registrations, or else it may have trouble updating the entries in the future.
Solution 2:
One of the way you can do this is by enabling DNS Aging/scavenging.
Please Backup your DNS and DHCP!
You will have to make changes in 2 places:
-
DNS SERVER [Enable aging/scavenging for all zones]
-Open you DNS server and open your zones
-Right Click > Properties > General Tab >Aging
-Check the "Scavenge stage resource records" -Change the No-refresh interval and Refresh interval from days to hours
Note: Don't forget to change it back to a appropiate interval when the dns is updated and you must take another step in DHCP server for this to work.
2. DHCP SERVER [Check DNS update settings for all scopes]
Open your DHCP server and click down to the scopes
Right click on your scope > Click Properties > DNS Tab
Take a note of your current settings and apply the highlighted settings from the image below
Note: Please backup your dns and dhcp before changing anything. This should bring your DHCP/DNS up to date