32
31

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Genymotionでadbが起動できない"adb server is out of date. killing…"が出た時の対応

Last updated at Posted at 2014-10-28

###事象
Android SDKを最新(21)にした後に、GenymotionでEclipseやAndroid Studioからアプリが起動しなくなる。ターミナルからadbを見てみると、以下のようなメッセージがでてくる。

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

またEclipseでアプリをrunすると、以下のようなメッセージがコンソールログにでる

 The connection to adb is down, and a severe error has occured.
 You must restart adb and Eclipse.
 Please ensure that adb is correctly located at '/Applications/sdk/platform-tools/adb' and can be executed.

###原因
GenyMotionが内部で利用しているadbが最新SDKでは利用ができなくなっている模様。

###対応
SDKのadbを参照するようにシンボリックリンクを貼る

事前にgenymotionのエミュレータは停止しておく。
1.genymotionのadbをbackupとっておく。

$ cd /Applications/Genymotion.app/Contents/MacOS/player.app/Contents/MacOS/tools/
tools $ ls
aapt	adb
tools $ mv adb adb-old

2.SDKのadbのシンボリックリンクを貼る

$ ln -s /Applications/sdk/platform-tools/adb adb
tools $ ls -all
total 6168
drwxr-xr-x@ 5 tomoaki  admin      170 10 28 12:31 .
drwxr-xr-x@ 8 tomoaki  admin      272 10  7 19:41 ..
-rwxr-xr-x@ 1 tomoaki  admin  1494864 10  7 19:41 aapt
lrwxr-xr-x  1 tomoaki  admin       36 10 28 12:31 adb -> /Applications/sdk/platform-tools/adb
-rwxr-xr-x@ 1 tomoaki  admin  1657696 10  7 19:41 adb-old

3.プロセス上に残っているadbを一度killする

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

4.Genymotionを起動すると、うまく接続できる

追記:Genymotionの設定からADBの参照先を変更できるようです。

スクリーンショット 2014-10-29 9.53.21.png

###参考

32
31
4

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
32
31

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?