36 articles and counting
      

Windows FlushDNS

Windows stores DNS information in a cache on your PC. The DNS Windows cache stores both Positive (successful host lookup) and Negative (unsuccessful host lookup) entries.

This is generally fine until your cache becomes out of date or your registry contains incorrect information.

I experienced this problem after having to re-install IE7 after I ran into some problems. I was running some applications locally and had entries in my /etc/hosts file to route these addresses to localhost. After reinstalling IE7 for some reason my cache got out of sync.

Fix:
At a command prompt type ipconfig /flushdns

This flushes the local DNS cache so we can start afresh.

You can also change your Registry if you want to control how Windows handles the DNS cache.

NOTE: Edit your registry at your own risk! You cannot hold us responsible for any problems you encounter following these instructions. They are a suggestion only!

Block Negative Entries
To force Windows XP NOT to cache negative entries we need to add a new DWORD to the following Registry key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet
\Services\Dnscache\Parameters
DWORD: MaxNegativeCacheTtl
Value: 0
This will now ensure NO negative entries are stored.
Cache TTL
To force Windows XP to keep positive entries in DNS Cache for only 4 hours instead of the default 24 hours we need to apply the following change to the registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\
Services\Dnscache\Parameters
DWORD: MaxCacheTtl
Value: 14400
NB – make sure you enter the 14400 (seconds) as Decimal Base and NOT Hexadecimal Base!

Block Negative Entries

To force Windows XP NOT to cache negative entries we need to add a new DWORD to the following Registry key:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Dnscache\Parameters

DWORD: MaxNegativeCacheTtlValue: 0

This will now ensure NO negative entries are stored.

Cache TTL

To force Windows XP to keep positive entries in DNS Cache for only 4 hours instead of the default 24 hours we need to apply the following change to the registry:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Dnscache\Parameters

DWORD: MaxCacheTtl

Value: 14400

NB – make sure you enter the 14400 (seconds) as Decimal Base and NOT Hexadecimal Base!