I have MacBook Pro (Retina, 13-inch, Early 2015) with OS X 10.11.5.
Internet connection works only for Chrome. Safari and several terminal apps cannot connect to internet due to resolve host failure.
I read the following posts in stackexchange that describe similar connectivity issues: My native mac apps are not connecting to the internet, but Google Chrome does and works correctly. Why is this?
On the terminal:
- ping google.com: ping: cannot resolve google.com: Unknown host
- ping 8.8.8.8: 5 packets transmitted, 5 packets received, 0.0% packet loss
- curl google.com: curl: (6) Couldn't resolve host 'google.com'
- curl 8.8.8.8: curl: (7) Failed to connect to 8.8.8.8 port 80: Operation timed
- ssh {servername} : ssh: Could not resolve hostname {servername}: nodename nor servname provided, or not known
- nslookup google.com: This works correctly.
- dig google.com: This works correctly.
I tried the followings a lot of times to no avail:
- Renewing/turning off&on/inputting manually DHCP.
- Restarting/resetting the router and the macbook.
- Turning WiFi on/off. This fixes the problem for a few minutes but then the connection drops again.
- Set all network configurations except wifi to "make service unavailable" in network preferences.
- Checked and copied all network settings from another macbook pro that's connected and online on my network.
- Ran network diagnostic and assistant tools
- Set Network > Wifi > Advanced > DNS > DNS servers to OpenDNS ip addresses: 208.67.222.222
- No Proxies is checked or set under Network > Wifi > Advanced > Proxies.
- Set TCP/IP > Configure IPv6 to "Link-local only" as suggested here: Constantly dropping internet on El Capitan?
- Logging in and connecting to internet with guest user account.
I tried running the following commands to reset DNS but they didn't run neither
$ sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist
/System/Library/LaunchDaemons/com.apple.mDNSResponder.plist: Could not find specified service
$ sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist
I didn't try the followings:
- Resetting SMC
- Removed the /Library/Preferences/SystemConfiguration folder.
- Removed network password from keychain.
Other information that might be relevant:
OS X Firewall is off.
I tried the following commands on terminal:
$ ifconfig en1 en1: flags=963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX> mtu 1500 options=60<TSO4,TSO6> ether 4a:00:03:bd:de:d0 media: autoselect <full-duplex> status: inactive $ ifconfig awdl0 awdl0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1484 ether 76:aa:18:a6:c9:49 inet6 fe80::74aa:18ff:fea6:c949%awdl0 prefixlen 64 scopeid 0x8 nd6 options=1<PERFORMNUD> media: autoselect status: active $ sudo ifconfig awdl0 down
I did the last command because it was suggested here: Constantly dropping internet on El Capitan?
My modem router has no black/whitelist for any MAC addresses.
skype app doesn't connect. It is stuck in "connecting" state.
flushing DNS cache didn't help neither:
$ sudo dscacheutil -flushcache
$ sudo killall -HUP mDNSResponder
No matching processes were found
Here are the DNS server settings:
$ cat /etc/resolv.conf
#
# Mac OS X Notice
#
# This file is not used by the host name and address resolution
# or the DNS query routing mechanisms used by most processes on
# this Mac OS X system.
#
# This file is automatically generated.
#
nameserver 192.168.43.1
I run
sysdiagnose
command to produce the following report:I can run
mDNSResponder
command on terminal. It returns no message back.