How to make XP re-read its HOSTS file?

  • Thread starter Thread starter throwaway_addr_12345
  • Start date Start date
T

throwaway_addr_12345

After making a change to C:\WINDOWS\system32\drivers\etc\hosts,
how do I get XP to see the changes short of logging off or rebooting?

I've tried restarting every service that looks even remotely related.
(And quite a few others.)

Is there a DOS command that will do it? NET HELP isn't really much
help... :)

Many TIA.
 
After making a change to C:\WINDOWS\system32\drivers\etc\hosts,
how do I get XP to see the changes short of logging off or rebooting?

I've tried restarting every service that looks even remotely related.
(And quite a few others.)

Is there a DOS command that will do it? NET HELP isn't really much
help... :)

Many TIA.

ipconfig /flushdns

This will flush the resolver cache, and re-load the hosts file to cache.

ipconfig /displaydns

will show the fresh contents of the cache.
 
nbtstat -R ...

will flush and reload the NetBIOS name cache from the LMHOSTS file.

The OP asked how to refresh the DNS name cache from the HOSTS file.

Quite a different animal.
 
Correct, I am not running the LM service, but thanks to both of you.

Cheers. :)
 
Back
Top