FLUSH – DNS Cache

Flush System DNS CACHE, IP Address Wisdom And More

DNS Flush

Tech | Tools – More Reference Than Tool, MacOS Flush DNS Cache

A few things to note: from time to time, you may need to flush your DNS cache, understand how your IP address is acting and how to dump, secure, or authorize computer code to start fresh.

Flush DNS Cache – MacOS
  • Plain text: sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder; say cache flushed
  • Or
  • 1. Command  + Spacebar
  • 2. Type Terminal, strike enter
  • 3. Select to Open ‘Mac Terminal Application’
  • 4. Type sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder; say cache flushed, strike enter
  • 5. Terminal will request “Sudo” password, enter Sudo password, and strike enter
  • 6. Assuming the password given is correct, the system will state “Cache Flushed as indicated in the terminal command
  • 7. Command  + W to close Terminal window
  • 8. Strike Enter to close out window
Flush DNS Cache – Windows
  • 1. Ctrl + R Run Windows Terminal
  • 2. ipconfig /all directing the system to flush all. For more information, you can look up more information by inputting ipconfig?
  • 3. Assuming no superuser credentials needed, strike enter
  • 4. Terminal will confirm, all released and renewed
  • 5. Ctrl + W to close Terminal window

Although this post may seem basic basic, at it’s core, it is. The command has been available since the dawn of the internet allowing users to reset the system as needed. This post will focus on the process of flushing the MacOS DNS Cache. I have included a snippet/script for resolving connection issues, tailored for both MacOS and Windows users who may come across this post. 

Experiencing lag? Before we proceed, please note that these terminal commands have been used for a while with limited changes over time. The only differences might be MacOS specific, directing the system to ‘speak aloud – Cache flushed’ when the command has been completed, among other actions. Flushing the DNS cache might just be the trick for your Mac. What exactly is this DNS flushing business? It involves skipping the process of physically deleting your local cache (not internet cache/cookies etc). I’ll also post something about that.

So, we are talking about flushing the DNS? Let’s begin with a brief explanation of DNS – Domain Name Server. If you need more information on DNS, you can check out Cloudflare’s Definition of DNS to understand how it works, and so on.  Essentially, the DNS translates domain names into  IP addresses, which are essential for navigating the internet. Without DNS, web browsers wouldn’t be able to load websites. For a more in-depth look, I recommend reading the  Cloudflare article for more details.

In a day or two, I will follow up with a post on WhatIsMyIPAddress about deleting ‘local user cache’ files on your Mac. It will make more sense in a few days if you haven’t a chance to troubleshoot your own computer issues related to internet speed, lag, and connections.

Leave a Reply