adb server is out of date. killing [duplicate]
Asked Answered
W

4

20

I'm creating my first react-native project with this tutorial: http://facebook.github.io/react-native/

When it comes to executing code and running react-native run-android I am getting:

adb server is out of date.  killing...
* daemon started successfully *

And the app on the android device is obviously not working.

I've reinstalled the SDK, tried to adb kill-server and adb start-server, but nothing seems to work

I'm using Android 4.4 and Ubuntu 14.04

Wheeler answered 19/4, 2016 at 23:34 Comment(2)
check this question . maybe helpful to you.Silence
updating adb helped. This link worked, official ubuntu adb packages were out of date by 0.01. Thanks!Wheeler
H
40

Open Android Studio, and then update all your build tools, install the SDKs that you need for your device and ensure that have you set ANDROID_HOME env var to the same dir that you have in Android Studio (commonly in /home/you/Android/Sdk), also update react-native-cli node package. Run adb kill-server and adb start-server.

Probably you will have problems with adb version, just change your bin:

sudo cp ~/Android/Sdk/platform-tools/adb /usr/bin/adb

sudo chmod +x /usr/bin/adb

Heighho answered 3/7, 2016 at 1:56 Comment(1)
Thanks. your work did the trick. Adb in /usr/bin was older than the adb in android sdk folderLoculus
W
14

In the latest adb update the adb server is out of date. killing... message has been replaced with more informative adb server version (%d) doesn't match this client (%d)

So this solution is applicable to both.

The root cause of the error is that your system has multiple adb binaries of different versions) installed. These adb binaries may come from different sources - distributed together with some development tools or even installed from your linux distribution official repository. I would strongly advise against using any of those sources. The official source of the most recent version of adb is the platform-tools package from the Android SDK. The adb tag info page contains the direct links to the package.

So if you have Android SDK already installed - just update the platform-tools package to the latest version using SDK Manager. If not - download and unpack the contents of platform-tools.zip file for your platform to a folder. Add that folder to your $PATH. Now kill all running adb processes and make sure to find all other copies of adb and delete them. In rare cases some software might stop working. In that case you would need either change that application's internal setting telling it where to find the new binary or if the application uses hard-coded adb location - just create a symlink to the new location.

That's it. No more server/client version mismatches. Although you might need to repeat the procedure after installing another software which comes prepackaged with its own adb copy.

Wooley answered 10/9, 2016 at 1:1 Comment(0)
C
11

It might be that you installed the adb package in addition to the SDK's. In that case, a

sudo apt purge adb

might solve the problem.

Cerebellum answered 17/5, 2017 at 15:27 Comment(0)
F
1

I'm getting this error using ADB (1.0.32) and Genymotion (2.8.2). My solution was change the ADB of the VM, from my local Android SDK's ADB to Genymotion ADB (default).

Fibered answered 13/10, 2016 at 7:58 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.