• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 41516
  • Last Modified:

How to Flush DNS cache in Mac OS X?

What is the Windows ipconfig /flushdns equivalent in Mac OS X?
  • 2
1 Solution
I'm not sure there's a need for it in OS X.
alexrsAuthor Commented:
When I change the IP address of an entry in the hosts file the system keeps resolving the associated name to the old address.
I figured out that if you go to Network Preferences and change the interface configuration (ex.: to manual address and then back to DHCP) it seems to reload it and clean the DNS cache. As a matter of fact I was expecting that "ifconfig down" and then "up" would cause the same effect, but it doesn't. I will stick to this workaround as the need is not very frequent.

Thanks anyway.

Closed, 125 points refunded.
Community Support Moderator
Experts Exchange
alexrsAuthor Commented:
Just found the equivalent to Windows' ipconfig /flushdns:

lookupd -flushcache

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now