Question Macbook Pro only connects to home wifi

Mar 7, 2019
3
0
10
I factory reset my Macbook Pro, running Mojave 10.14.3. Now it connects to my home wifi network without any problem. But if I try to connect it to any other wifi network, it does not. Just keeps on showing -- Resolving Host....!

Rebooting to directly connect to the new network also does not help. Once I reconnect to home wifi, everything gets back to normal. Not using any VPN etc. I read somewhere that Renewing DHCP lease could help, but it does not.

Any pointers. Thanks
 
From that description, it sounds like it might be a DNS issue. Try flushing the DNS cache on your Mac by opening the Terminal and entering the command below:

sudo killall -HUP mDNSResponder

Copy/Paste that command above, as it is case sensitive. Failure to type it out EXACTLY as shown will result in the command failing to run at all. Also note that you will need to know an admin password to be able to run it.

If that doesn't work, you can also try modifying the DNS servers your Macbook is using. You can find them in System Preferences > Network > highlight the Wifi entry in the list and click Advanced > click the DNS tab. From there you can add DNS servers to use instead of the one the Wifi access point is set to use for all connected clients. For instance, I use Google's public DNS servers for client machines I work on: 8.8.8.8 and 8.8.4.4.
 
  • Like
Reactions: sjgoel
Mar 7, 2019
3
0
10
From that description, it sounds like it might be a DNS issue. Try flushing the DNS cache on your Mac by opening the Terminal and entering the command below:

sudo killall -HUP mDNSResponder

Copy/Paste that command above, as it is case sensitive. Failure to type it out EXACTLY as shown will result in the command failing to run at all. Also note that you will need to know an admin password to be able to run it.

If that doesn't work, you can also try modifying the DNS servers your Macbook is using. You can find them in System Preferences > Network > highlight the Wifi entry in the list and click Advanced > click the DNS tab. From there you can add DNS servers to use instead of the one the Wifi access point is set to use for all connected clients. For instance, I use Google's public DNS servers for client machines I work on: 8.8.8.8 and 8.8.4.4.

Thanks. It was not a DNS issue. It was due to old preferences still around after upgrade. So a force rebuild of all new preference files for wireless networking helped settle the problem.
 
Mar 29, 2019
2
0
10
baltazaar.wordpress.com
Removing old entries in the list of known networks often does the trick.

Check if your Wifi is up using:

Code:
ifconfig -u en0

For resolving stale DHCP and DNS issues, issue the following command in a Terminal to reset the WiFi adapter and flush the DNS cache:

Code:
sudo ifconfig en0 down && dscacheutil -flushcache && sudo ifconfig en0 up && ifconfig -u en0

I've mapped the alias 'wifireset' to trigger this in my ~/.zshrc file, so I can just fire up a terminal and issue wifireset, to do the work.
You can do the same in ~/.bashrc if you use Bash as a login shell.
Also, I've added a nice alias command 'myip' to check your external IP address, which can come in handy as well!

Code:
# Reset Wifi
alias wifireset="sudo ifconfig en0 down && dscacheutil -flushcache && sudo ifconfig en0 up && ifconfig -u en0"
# Get external IP via dig
alias myip="dig +short myip.opendns.com @resolver1.opendns.com"