ADB Genymotion Upgrade Issue: Devices Not Showing Up (“adb server is out of date. killing…”)

I upgraded a lot of things on my system. From Mavericks to Yosemite (upgrading the entire Mac operating system itself) to upgrading the Android SDK with Eclipse as well as Android Studio from 0.6.1 to 0.8.6.

After all these upgrades, Genymotion stopped working with Android Studio (my preferred Android IDE). Although it was firing up but didn’t show up in the devices list when trying to run the app. The command adb devices also gave a strange message of not being able to bind to a particular TCP port:

What's the one thing every developer wants? More screens! Enhance your coding experience with an external monitor to increase screen real estate.

$ adb devices
adb server is out of date.  killing...
cannot bind 'tcp:5037'
ADB server didn't ACK
* failed to start daemon *
error:

I wasn’t sure why this happened but maybe due to the upgrades and maybe with the new Android L (Lollipop) SDKs this issue might have popped up. Anyway, I tried to see what’s bound to tcp:5037 using lsof command:

$ lsof -n -i4TCP:5037 | grep LISTEN
adb     761 rishabhpugalia   17u  IPv4 0x692a354f892d3e13      0t0  TCP 127.0.0.1:5037 (LISTEN)

Interesting, it’s adb itself with a process ID (PID) of 761. On checking the process list I found this:

$ ps ax | grep adb
  820   ??  S      0:00.02 adb -P 5037 fork-server server
  822   ??  S      0:00.02 /Applications/Genymotion.app/Contents/MacOS/tools/adb -s 192.168.56.101:5555 shell
  824 s000  R+     0:00.00 grep adb

So seems like Genymotion uses its own version of adb which is probably the one from my Mavericks installation and not compatible with the newest SDK that’ve been installed. So I guess we could either reinstall Genymotion or try this solution that I found on the internet which worked well for me:

$ cd /Applications/Genymotion.app/Contents/MacOS/tools/
$ ls
aapt		adb		glewinfo
$ mv adb adb-old
$ ls
aapt		adb-old		glewinfo
$ ln -s ~/adt-bundle-mac-x86_64-20140702/sdk/platform-tools/adb adb
$ ls -alh
total 7096
drwxr-xr-x@ 6 rishabhpugalia  admin   204B Oct 18 07:43 .
drwxr-xr-x@ 9 rishabhpugalia  admin   306B May 26 20:46 ..
-rwxr-xr-x@ 1 rishabhpugalia  admin   1.4M May 26 20:31 aapt
lrwxr-xr-x  1 rishabhpugalia  admin    75B Oct 18 07:43 adb -> /Users/rishabhpugalia/adt-bundle-mac-x86_64-20140702/sdk/platform-tools/adb
-rwxr-xr-x@ 1 rishabhpugalia  admin   1.6M May 26 20:31 adb-old
-rwxr-xr-x@ 1 rishabhpugalia  admin   512K May 26 20:31 glewinfo

We sort of backed up the adb in Genymotion and then created a new file which is a symlink to the one in our newly downloaded and installed ADT bundle. Your folder name might not be adt-bundle-mac-x86_64-20140702 and vary

Next, try killing your existing adb processes via the kill command or activity monitor or $ adb kill-server might work too.

Finally, you’ll be able to check devices properly and if you run the Genymotion emulator it’ll show in the list of devices too.

$ adb devices
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
List of devices attached

# After firing up Genymotion emulator

$ adb devices
List of devices attached
192.168.56.101:5555	device

Hope that helps save some headache!

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download

Author: Rishabh

Rishabh is a full stack web and mobile developer from India. Follow me on Twitter.

5 thoughts on “ADB Genymotion Upgrade Issue: Devices Not Showing Up (“adb server is out of date. killing…”)”

  1. This solution didn’t work for me, but I found that Genymotion has a built in way to fix this. Check Settings -> ADB in Genymotion and you have the option of pointing it to a custom ADB location. Setting my sdk path here fixed things for me.

    1. This worked for me, the post content didn’t, tho it makes sense. I guess Genymotion uses something more than just adb

Leave a Reply

Your email address will not be published. Required fields are marked *