The Domain Name System (DNS) translates the names of websites to IP addresses (numeric/alphanumeric format) so that the website loads for the users. In simple words, the DNS is responsible for the websites to load on your computer. If websites do not load, flushing the DNS resolver cache memory can bring the websites back.
This article is all yours if you have a website that is not loading on your browser and need to clear out the DNS entries.
What does flushing the DNS mean?
Flushing DNS cache refers to the process of removing the IP addresses or the DNS resolver cache of the internet connection to fix issues related to digital security and network connection. The existing DNS address is removed and set to automatically finding a DNS or IP address. This task can be done manually or without any action.
Even though the DNS cache keeps flushing itself on its own because of a feature known as the Time to Live (TTL). One specific DNS entry is valid for the duration of the TTL. After the time runs out, it will be reset automatically.
Generally, a reboot of the router and the ipconfig /flushdns command in the Windows 10 command prompt can help you clear this out.
Why should you flush the DNS Resolver cache?
The following are the reasons why you need to flush the local DNS cache, manually, without having to wait for the TTL to run out:
- 404 errors are common symptoms for the wrong DNS. If you see a 404 error or an old version of the website that you try to load.
- The website might not load.
You can clear the browser cookies, history, and browser settings to see if the website loads. If it doesn’t, flushing the DNS is your solution.
- Changing the DNS address can protect your browsing privacy. This can save you from sites that collect your information.
- You can flush the DNS cache to avoid attackers from gaining access to your information and taking you to irrelevant domain sites.
Flushing Your DNS Cache
3 Ways to Flush the DNS Cache in Windows 10
There are three ways to flush the DNS cache in Windows 10.
1. Windows Command
- Press the Windows plus R keys to launch the Windows Run utility.
- In the Open field, type in this command:
- Press the Enter key to clear the DNS server address.
You will see the message “Windows IP Configuration Successfully flushed the DNS Resolver Cache” after the process is complete and the DNS cache will be changed.
2. Windows PowerShell
- Right-click on the Start button or press Windows key + X to bring up the Quick Link menu.
- Choose Windows PowerShell (Admin). Alternatively, you can search for PowerShell and choose to run it as the admin.
- Type the following command in the interface:
- Press the Enter key to run this command.
3. Command prompt
- Click on the search bar, type cmd and you should be able to see the Command Prompt window & related options. The cmd command can also be used in the Run tool to open the command prompt.
- From the search results, choose Run as Administrator.
- Type ipconfig /flushdns in the Command Prompt window and hit Enter.
How to Flush DNS Windows 7
The earlier OS Window 7 also has a similar way to flush the DNS cache on your computer. This uses the command prompt tool too.
These are the steps to flush your DNS cache if you work with Windows 7:
- Click on the Start button on the lower-left corner of the screen.
- Select the All Programs option and choose Accessories from this.
- Locate the Command Prompt tool, right-click on it and select Run as Administrator.
- Choose Yes in the prompt window, that appears and asks if you want to let the Command Prompt make changes in your computer. If you are not the system administrator, you will need their help to move forward with this operation.
- Type in the ipconfig /flushdns command and press Enter to flush the DNS cache.
After it is complete, you will see a message that states that the DNS Resolver cache was successfully flushed.
How to Flush DNS Windows XP and Vista
The process of flushing the DNS cache on Windows XP and Vista is very similar to the same process in Windows 7.
These are your steps to flush DNS cache in Windows XP and Vista:
- Press the Windows key or click on the Start button to bring up the Start menu.
- Open All Programs and choose the Accessories option.
- From this, open the Command Prompt tool.
- Type ipconfig /flushdns and hit Enter in the Command Prompt window.
- You might receive the “Action Requires Elevation” message. In that case, the admin has to follow the above-mentioned procedure.
How to Flush DNS Mac OS X
Every Mac OS version on your Mac has the same method to change the DNS Resolver Cache. But the Terminal Command may differ.
These are the steps and commands to flush the Mac DNS:
- Press the Option + Command + Space keys on the keyboard to open the Finder tool.
- Choose Applications and locate the Utilities folder.
- Open it and launch the Terminal application. Alternatively, you can start the Launchpad and search for Terminal in it.
- The following commands have to be entered in the Terminal, on the basis of the software version:
- Version 10.4: lookupd -flushcache
- Version 10.5 – 10.6: sudo dscacheutil -flushcache
- Version 10.7 – 10.9: sudo killall -HUP mDNSResponder
- Version 10.10: sudo discoveryutil mdnsflushcache
- Version 10.11 – 10.14: sudo killall -HUP mDNSResponder
- Type in the password and press Enter.
- A confirmation message will let you know when the DNS server address has been flushed.
How to Flush DNS Google Chrome
The Google Chrome browser has a functioning DNS cache of its own. This can be changed through Chrome in MacOC or Windows 10 and the steps are the same.
These are your steps to clear the Chrome browser’s cache:
- Launch the Chrome and type in the following inside the address bar on top:
- Press the Clear host cache button to clear your DNS server.
How to Flush DNS Linux
The Linux OS does not get a DNS address, at standard. Linux users have two options – clear the DNS cache or restart the Linux system service.
This is what you have to do:
- Start the Terminal tool by pressing the Ctrl + Alt + T on your keyboard.
- Enter the following commands, depending on the Linux service that runs your system:
- Dnsmasq: sudo /etc/init.d/dnsmasq restart
- NCSD: sudo /etc/init.d/nscd restart
- BIND: This one has a number of commands
- sudo /etc/init.d/named restart
- sudo rndc exec
- sudo rndc restart
Frequently Asked Questions
What does flushing the DNS do?
Flushing the cache will help you get rid of outdated entries, problems with loading a website, or correct the internet IP address on your computer.
Is Flushing DNS bad?
The DNS flushing process is a safe process. In fact, it improvises your web security, clears the path to a domain name, and removes old entries.
How do I reset my IP address and flush DNS Windows 10?
If you wish to reset the IP, type in ipconfig /release and then ipconfig /renew and run these commands. Open the command prompt and enter ipconfig /flushdns to reset the DNS address on Windows 10. You can also change it using PowerShell and a Windows command.
Does a reboot flush DNS?
Rebooting Windows 10 does not clear your DNS, but rebooting the router can reset it and clear all the existing entries in the router’s temporary memory.