How can I view and clear my DNS cache content?

Learn how to view and clear the DNS cache content.

John Savill

October 22, 2002

1 Min Read
How can I view and clear my DNS cache content?

A. When a Windows XP or Windows 2000 machine queries a DNS server, the response is either positive (a match was found) or negative (no match was found). The OS stores these results in a local DNS cache so that local clients don't repeatedly query the DNS server for the same address. These DNS cache entries are known as DNS resource records, and the DNS resolver always checks the local cache before it queries the DNS server.

To view the current DNS resolver cache content and the entries preloaded from the Hosts file, go to the command prompt and type

C:> ipconfig /displaydns

Each entry shows the remaining Time to Live (TTL) in seconds. To clear the cache, go to the command prompt and type

C:> ipconfig /flushdns

Flushing the DNS cache clears all entries and reloads the entries from the Hosts file.

Learn more from "Clear Out Cached Data" and "How can I clear the contents of the DNS resolution cache in Windows 2000 and later?"

About the Author(s)

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like