flush DNS OSX code example
Example 1: how to flush dns on mac
dscacheutil -flushcache; sudo killall -HUP mDNSResponder
Example 2: flush dns cache linux
sudo systemd-resolve --flush-caches
dscacheutil -flushcache; sudo killall -HUP mDNSResponder
sudo systemd-resolve --flush-caches