How to Clear DNS Cache Mac – cmd flush dns on a Mac

Video is ready, Click Here to View ×


How to flush dns osx

How to Clear or Flush DNS Cache in Mac OS X Yosemite or El Capitan

Here is the the DNS flush command:

sudo dscacheutil -flushcache;sudo killall -HUP mDNSResponder; say cache flushed

Basically the reason you do this is to fix an issue when you put in a name of a server or website in your browser or try to mount a server and it doesn’t go to the right place. This clears the DNS cash and then it automatically rebuilds a new one with the accurate matching ip addresses.

In more detail OS X keeps a local cache of resolved DNS queries for a time defined by the DNS server. Sometimes it might be necessary to reset the cache immediately and re-query a DNS server. For example, you might need to do this if you are a network or server administrator and an entry on your DNS server has recently changed.
If your Mac isn’t using the latest DNS entries from your server, you can restart your Mac to update its cached information. If you need to update DNS entries on a server using OS X and you can’t restart the server, use the terminal commands below for the version of OS X you’re using.

El Capitan and Yosemite

sudo dscacheutil -flushcache;sudo killall -HUP mDNSResponder; say cache flushed

OS X Yosemite and later
Use the following Terminal command to reset the DNS cache in OS X v10.10.4 or later:

sudo killall -HUP mDNSResponder

Use the following Terminal command to reset the DNS cache in OS X v10.10 through v10.10.3:

sudo discoveryutil mdnsflushcache

OS X Mavericks, Mountain Lion, and Lion
Use the following Terminal command to reset the DNS cache in OS X v10.9.5 and earlier:

sudo killall -HUP mDNSResponder

Mac OS X Snow Leopard
Use the following Terminal command to reset the DNS cache in OS X v10.6 through v10.6.8:

sudo dscacheutil -flushcache

cmd flush dns

osx flush dns

cached dns records

flush dns command

How to Clear DNS Cache Mac – cmd flush dns on a Mac

dns error — clear cache on mac

3 comments

  1. I cleared my cache successfully but can still only go on google and google owned sites. This isn't the case on my other devices that are on the same Wi-Fi network. Any tips?

Leave a Reply

Your email address will not be published. Required fields are marked *