Yet Another OSX Yosemite Wifi / Bluetooth Connectivity Fix

Some users have problems with OSX Mavericks/Yosemite wifi connectivity – there’s all sorts of things that can go wrong.

This stackexchange thread has a variety of solutions that you should probably try.

Did you reset your SMC, NVRAM, and a dozen other fixes as recommended from that thread? Yeah? Still have a problem? Me too.

Pro tip: DON’T reinstall a fresh copy of yosemite, that won’t fix it either.

In my case, we narrowed the problem down to bluetooth / wifi interference. Wifi and bluetooth both share 2.4ghz spectrums, and at least 1 (mine) of out 3 macbooks in our office has some problem going on. (Though, tbh, if it was just interference, it’d seem all 3 macbooks would have this same problem at least once in a while.)

Here’s how you can test if this is the same problem that you’re suffering.

  1. Open terminal.
  2. Run ping www.google.com.
  3. Watch output scroll by, usually something like: 64 bytes from 216.58.218.164: icmp_seq=1 ttl=53 time=15.730 ms
  4. Wait until you get something like this, consistently: Request timeout for icmp_seq 29
  5. While you’re seeing the request timeout responses in terminal, turn off bluetooth for your computer.
  6. If you’ve got the same problem as me, connectivity resumes and ping output comes back online the moment you turn bluetooth off.

Is this problem affecting you? Ok, Popular solutions to this problem:

  1. Re-situate your computer and bluetooth devices to avoid interference.
  2. Use a non-bluetooth mouse, keyboard, whatever; and turn bluetooth off.
  3. Change to a 5ghz wifi connection if possible.
  4. Remove the bluetooth pan network connection over in the network settings panel.
  5. Don’t spend $2500 on a computer and $70 on a bluetooth magic mouse and expect them to work.

That last solution is a joke, kind of.

Anyway, if like me, none of the above helps. I’ve written a bash script to auto detect the connectivity issue and auto cycle bluetooth on/off.

The script is annoying if you’ve got a bluetooth keyboard or mouse because input stops for a moment while bluetooth cycles off/on – but, the script works.

To run it, do this:

  1. Open terminal.
  2. In terminal, install homebrew if you don’t already have it. Homberew is awesome.
  3. In terminal, install the blueutil utility with homebrew (with brew install blueutil).
  4. Download my script, save it to your desktop.
  5. Review the code in my script, because we all know not to run software we don’t trust.
  6. In terminal, make my script executable in a terminal with cd ~/Desktop && chmod +x fixmacbookwifi.sh
  7. In terminal, run my script like so: cd ~/Desktop && ./fixmacbookwifi.sh 15 SOMEHOST, where SOMEHOST is a website or network computer that won’t mind you pinging it once in a while, like www.google.com (if you have no other option..).

It’s annoying, but it works for me on my 2014 Macbook Pro (Retina 15in mid 2014 / MacbookPro11,2 / OSX 10.10.5).

Drop me a line if you find a better / permanent solution to this problem.