Option 1 – Locate and click the Apple icon in your upper left corner and click “System Preferences”, then “Network” and search for “DNS Server”. If you want to modify and remove malicious entry, you can simply click the box and input the right address. However, if you are not sure simply try release & renew as instructed below.
Option 2 – Open Terminal (~/Applications/Utilities or you can search it using spotlight)
From the terminal, type “cat /etc/resolv.conf”. This command will return your domain and name servers.
Another command is, “scutil –-dns”. Check resolver #1, this often returns domain and name servers as well.
Release and Renew to remove malicious DNS entry
From the terminal, type the following:
sudo ifconfig en1 down
sudo ifconfig en1 up
**Note: sudo means run as root user, so it will require you to input password. Also, en1 is often interfaced to LAN and en0 to Wireless – just try and see which one will work.
Another way is to unplug your internet connnection and reconnect. This will also work (”,)