2

I have created a host entry. I recently needed to change the IP of the host entry, however some clients in the domain are still looking at the old ip of the host...

How can I cause a network wide refresh?

Am I correct to assume DNS entries are cached client side and a DNS flush per client might be required?

2 Answers 2

6

This information is held in the DNS cache on the client. If the client has already resolved the name to IP address it is more efficient to pull the data from the cache than to query DNS each time.

On an individual workstation you would use the command ipconfig /flushdns to empty the cache and force fresh DNS lookups. The default time an entry will stay in the cache is 1 day. http://support.microsoft.com/kb/318803/en-us. It might be eaiser to have clients with the old IP address run the /flushdns command rather than rig something to clear the cache domain-wide.

1
  • 1
    +1 - That's accurate. You could use something like "PSEXEC" and a list of computer names to perform such a "domain-wide DNS cache flush". (Alternatively, you could just use the "sc" command and remotely stop and restart the "DnsCache" service on all the computers, which would accomplish the same thing...) Dec 22, 2009 at 14:01
1

Just found this little vbscript:

'Author: Lair360
'Version: 16.6a
'Revision: 36 Build 16
'--------------------------------------------
On Error Resume Next 'This line will cancel the error and direct to the info.
Dim objShell 'This will maintain memory usage when "WS.script.Shell" is activated.
set objShell = createobject("wscript.shell")
objShell.run("%comspec% /k c: & ipconfig /flushdns")
'Results are given and cmd command-line has exit.
WScript.Quit
'End of VBScript command
'-------------------------------------------
WScript.Echo "DNS Caches are flushed!"
objShell = Nothing
'VBScript Ends

You can launch it on your workstations using GFI network scanner for example.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .