“Failed to parse the output of 'adb version'”, “The connection to adb is down, and a severe error has occurred”

。_饼干妹妹 提交于 2019-12-24 00:42:09

问题


At the moment I can't even get the Hello World app from the Android tutorial to work. I'm trying to run it on my Galaxy S4. My phone has USB debugging enabled and has USB verification of apps disabled. I have Android 4.2.2 SDK (API17) downloaded and installed and am currently using Eclipse with the ADT plugin on Windows.

First it gives the "Failed to parse the output of 'adb version'" error message and then prints the following in the console:

[2013-06-12 23:02:50 - TestApp] ------------------------------
[2013-06-12 23:02:50 - TestApp] Android Launch!
[2013-06-12 23:02:50 - TestApp] The connection to adb is down, and a severe error has occured.
[2013-06-12 23:02:50 - TestApp] You must restart adb and Eclipse.
[2013-06-12 23:02:50 - TestApp] Please ensure that adb is correctly located at 'C:\Program Files (x86)\Android\android-sdk\platform-tools\adb.exe' and can be executed.

The command "adb devices" shows both my phone and an emulator, and running from the emulator doesn't work either. It doesn't even let me choose what device I want to run on, it just gives the error immediately.

What I've tried so far:
restarting my computer
adb kill-server/start-server and restart Eclipse
going to Task Manager and ending the adb.exe process, then restarting Eclipse
adding adb.exe as trusted/closing firewall
made sure I installed all the correct drivers
uninstalled Eclipse and redownloaded the ADT bundle
copied the contents of sdk/platform-tools to sdk/tools (and I saw in another thread someone suggested copying to sdk/tool but I didn't find a folder named that so I created one)

in the process of trying: updating JDK to latest version using Android Studio

edit: Downloaded the ADT bundle from the Android Developer site and I'm still getting the same issues with their version of eclipse.


回答1:


Your adb is not located in tools folder. Here is the Solution:

  • In folder: \android-sdk-windows\ go to folder \platform-tools

  • Copy the files and paste them into folder \tools

  • Restart Eclipse




回答2:


As I said in the comment above, I reinstalled the ADT Bundle after installing Android Studio and everything seems to be working fine now. I'm afraid of uninstalling Android Studio just in case something about it is keeping ADT working. Not sure why this is, but it's another potential solution.




回答3:


After much trials and errors on the several listed solutions, this is what worked for me. I added the following path to my enviromental variables PATH and restarted eclipse and worked like a charm... <path to sdk>\platform-tools



来源:https://stackoverflow.com/questions/17080423/failed-to-parse-the-output-of-adb-version-the-connection-to-adb-is-down-a

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!