Flush DNS cache Mac OSX

Create a file flush_dns.sh

chmod 755 flush_dns.sh

edit and paste the code bellow:

#!/bin/bash
sudo dscacheutil -flushcache;
sudo killall -HUP mDNSResponder;

How useful was this post?

Average rating / 5. Vote count:

No votes so far! Be the first to rate this post.

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.