Flush DNS’s Cache

Looking for a way to flush your DNS’s cache?

It’s as easy as:

sudo lookupd -flushcache

ipconfig /flushdns

Update: This command has changed in Leopard. Use the following command:
dscacheutil -flushcache


 
 

9 Responses to “Flush DNS’s Cache”


  1. Trackback
    Surf 11

    Flush DNS Cache on Mac OSX


  2. 4Avatars
    weee
    Um, what exactly does this do? I'm a serious n00b - and a recent switcher. But I'd like to get learn and start to use the terminal and stuff. So, um, thanks?

  3. Basically when you send a request (like google.com) to a DNS server, it gives you an IP address (like 255.255.255.255). When you flush the DNS cache, you're telling the DNS server to actually check for an updated IP address instead of using the old cache file.

    Hopefully I explained that alright.

  4. 4Avatars
    R
    'sudo' shouldn't be necessary.

  5. 4Avatars
    Bill
    Hmm, no workie....

    $ sudo lookupd -flushcache
    sudo: lookupd: command not found

  6. Bill, Try a 'whereis lookupd' and using the full path to lookupd.

  7. 4Avatars
    chrisb
    This changed in Mac OSX Leopard 10.5 to
    dscacheutil -flushcache
    see the man page for dscacheutil: man dscacheutil

  8. Thanks for the reply chrisb, I'll update the post to reflect the changes.

  9. 4Avatars
    Rob
    Or, you could use this handy dandy little GUI app "DNS Flusher":

    http://homepage.mac.com/minge/dnsflusher/

Post a comment to "Flush DNS’s Cache"



Support MacTips

MacTips Newsletter


Random Popular Tips

Recent Comments

Recent Discussions

MacTips Poll

What level of tips would you like to see?

View Results

Loading ... Loading ...

Friends of MacTips

Subscribe to MacTips

Site Links