14

The strange problems I am having occurred 3 times now with a little over 1 month in between. Suddenly I am losing the ability to do some network related activities, but not all.

When it happens, these still work:

  • Resolve domain names using eg ping / dig
  • Skype
  • Fantastical (with google calendar sync)
  • SSH connections are not disconnected, but I can not create new ones
  • I can ping, and get responses back

However, these do not work:

  • All browsers (Chrome, Firefox, Safari), won't display pages.
  • Connected web-pages that uses web-sockets or SSE are losing connections (both over http and https).
  • Curl won't grab pages.
  • Adium disconnects and won't reconnect.
  • Sonos (inside my LAN) won't work anymore.
  • Evernote stops syncing.

The output of curl trying to grab a page is showing Can't assign requested address

{ ~ }$ curl google.com
curl: (7) Failed to connect to 84.208.42.35: Can't assign requested address 

My ifconfig looks just like it should.

netstat -an doesn’t contain an overwhelming number of entries:

1 CLOSE_WAIT
1 SYN_SENT
2 CLOSED
2 FIN_WAIT_2
13 FIN_WAIT_1
16 LISTEN
212 LAST_ACK
446 ESTABLISHED

I am on a MacBook Pro early 2011 model running OS X 10.9.1 connecting over wireless. This is the only device on the network with this problem. The only thing that helps is restarting the Mac. There are really not much to see in the logs either (as I've spotted at least), only services having sudden problems connecting.

Has anyone else been having problems like this? What is the best way to troubleshoot this the next time it happens?

  • 3
    what you're describing seems to be this issue perhaps; i would file a bug report with Apple. – l'L'l Jan 15 '14 at 23:20
  • @xeor, I guess you've already updated the firmware of network devices but please confirm the version of firmware. Also, you can compare current good condition and bad condition by taking logs using Wi-Fi explore.app@appstore and wireshark. – Juza Feb 23 '14 at 7:22
  • A. Install and start arpwatch and set it to log to a file. – Sherwood Botsford Feb 28 '14 at 4:45
  • B. run netstat -nr before and during a problem session. – Sherwood Botsford Feb 28 '14 at 4:46
  • C. Has your router been pawned? – Sherwood Botsford Feb 28 '14 at 4:47
11

As l'L'l stated, this problem does seem to be described here:
https://discussions.apple.com/thread/5551686?start=45&tstart=0

A temporary solution would be to open terminal and type:

sudo ifconfig en0 down
sudo route flush
sudo ifconfig en0 up

replace en0 with whatever port you are using to connect to the internet. This command essentially resets your connection without having to reboot your computer.

3

The ifconfig + route flush solution by @blaine prompted me to look in netstat -nr and sure enough I had a static host route to the gateway, with a high usage count (5th column in the netstat -nr output.)

When this happens again, you might want to check if you have a route for the address prefix that you are trying to connect to, and if it exhibits the same issue. For me, I didn't have to bring down the interface; just doing a route delete <dest> <gateway> (and adding it again if necessary) worked.

protected by Community Apr 10 '14 at 0:39

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.