Clear DNS Cache: Flushing the DNS cache helps resolve many HTML 404 error codes. By doing this, clearing the DNS cache, the computer queries nameservers for any new DNS information. You can do so via commands like the ipconfig/flushdns cmd commands and the dscacheutil -flushcache on MAC OS.
What is the DNS cache?
The DNS cache stores the IP addresses of web servers that contain web pages which you have recently viewed. If the IP address of the web server changes before the entry in the DNS cache updates, users will no longer be able to access the site.
Clear DNS Cache
As far as flushing the DNS cache goes, you can do so in different ways and, it sometimes depends on the operating system that you use. The following methods allow you to remove old and inaccurate DNS information that may result in 404 errors.
How do you flush DNS server?
The following applies to clearing the DNS cache on Windows Server 2003, Windows Server 2003 R2, Windows Server 2003 with SP1, Windows Server 2003 with SP2:
Flush and reset a client resolver cache using the ipconfig command
- Open Command Prompt.
- Type:
ipconfig /flushdns
To open a command prompt window, click Start, point to All programs, point to Accessories, and then click Command prompt. The ipconfig /flushdns command provides you with a means to flush and reset the contents of the DNS client resolver cache.
How do I clear the cache on Windows 8.1?
To flush the DNS cache on Windows 8, do the following steps:
- On your keyboard, press Win+X to open the WinX Menu.
- Right-click Command Prompt and select Run as Administrator.
- Run the following command:
ipconfig /flushdns
Once the command succeeds, the system returns the following message:
Windows IP configuration successfully flushed the DNS Resolver Cache.
How do I clear the cache on Windows 7?
To clear the DNS cache on Windows 7, you need to perform the following steps:
- Click Start.
- Enter
cmd
in the Start menu search text box. - Right-click Command Prompt and select Run as Administrator.
- Run the following command:
ipconfig /flushdns
Once the command succeeds, the system returns the following message:
Windows IP configuration successfully flushed the DNS Resolver Cache.
How do I flush the cache on Windows Vista?
To clear your DNS cache if you use Windows XP, 2000, or Vista®, perform the following steps:
- Click Start.
- On the Start menu, click Run….
- If you do not see the Run command in Vista, enter
run
in the Search bar.
- If you do not see the Run command in Vista, enter
- Run the following command in the Run text box:
ipconfig /flushdns
Once the command succeeds, the system returns the following message:
Successfully flushed the DNS Resolver Cache.
Video: Flush DNS using Command Prompt on Windows
How do I flush the cache on MacOS®?
o clear your DNS cache if you use MacOS X version 10.10, perform the following steps:
- Click Applications.
- Click Utilities.
- Click Terminal.
- Run the following command:
sudo
discoveryutil mdnsflushcache
If the command succeeds, the system does not return any output.
Warning:
To run this command, you must know the computer’s Admin account password.
MacOS 10.7, 10.8, and 10.9
To clear your DNS cache if you use MacOS X version 10.7, 10.8, or 10.9, perform the following steps:
- Click Applications.
- Click Utilities.
- Double-click Terminal.
- Run the following command:
sudo
killall -HUP mDNSResponder
If the command succeeds, the system does not return any output.
Warning:
To run this command, you must know the computer’s administrator account password.
MacOS 10.5 and 10.6
To clear your DNS cache if you use MacOS X version 10.5 or 10.6, perform the following steps:
- Click Applications.
- Click Utilities.
- Double-click Terminal.
- Run the following command:
sudo
dscacheutil -flushcache
If the command succeeds, the system does not return any output.
Warning:
To run this command, you must know the computer’s administrator account password.
Video: Flush DNS on a Mac including (OSX Mavericks)
Tutorial showing you how to flush the DNS on a Mac including OSX Mavericks. This video makes use of the mac terminal and dscacheutil tool. Mac OSX Mavericks 10.9 use this, dscacheutil -flushcache; sudo killall -HUP mDNSResponder; Prior to 10.9 use dscacheutil -flushcache;
Bonus: How do you clear your IP address?
- Go to “Start > Run” and type ” cmd ” (no quotes)
- select “OK”
- Type ” ipconfig /release ” (no quotes) and press “Enter”
- Once the prompt returns, type ” ipconfig /renew ” (no quotes), then hit “Enter,”Finally, type “exit” (without quotes) then press “Enter” to close the window