错误“与adb的连接已关闭,并且发生了严重错误。”

本文翻译自:Error “The connection to adb is down, and a severe error has occurred.”

I've spent days trying to launch any Android program. 我花了几天时间尝试启动任何Android程序。 Even "Hello World" gives me the same error: 甚至“Hello World”也给了我同样的错误:

"The connection to adb is down, and a severe error has occurred". “与adb的连接已关闭,并且发生了严重错误”。

I'm running Eclipse v3.5 (Galileo), Google APIs 2.2.8, on a Windows XP machine. 我在Windows XP计算机上运行Eclipse v3.5(Galileo),Google API 2.2.8。

I've used all the tricks I can find on the web: the command line "adb kill-server", the DDMS "reset ADB", I started the emulator both before and after Eclipse, and searched for ports being used by other programs. 我已经使用了我可以在网上找到的所有技巧:命令行“adb kill-server”,DDMS“重置ADB”,我在Eclipse之前和之后启动了模拟器,并搜索了其他程序使用的端口。

What is going on here? 这里发生了什么? Is there a magic combination of versions of Eclipse, Java, ADB, emulator, and whatever else that works? 是否有Eclipse,Java,ADB,模拟器等版本的神奇组合,以及其他有效的版本?


#1楼

参考:https://stackoom.com/question/h5uO/错误-与adb的连接已关闭-并且发生了严重错误


#2楼

The killing of the mysteriously running abd.exe worked. 杀死神秘运行的abd.exe有效。 This sudden roadblock stopped me for a long time. 这个突然的障碍阻止了我很长一段时间。 I was doing all sorts of command line stuff and removed the lock icon from my user folder, but nothing worked until your simple suggestion of looking for the abd in the running processes of the task manager and killing it. 我正在做各种命令行的东西,并从我的用户文件夹中删除了锁定图标,但是直到您在任务管理器的运行进程中查找abd并将其删除的简单建议之前没有任何工作。

Another newbie roadblock I discovered an answer to: don't run Eclipse when any file other than the main .java file is active. 另一个新手路障我发现了一个答案:当主.java文件以外的任何文件处于活动状态时,不要运行Eclipse。 If you run it when, for example, the main.xml file is active, you will get unhelpful error messages, an odd file created like main.xml.out, and it wont run. 例如,如果在main.xml文件处于活动状态时运行它,则会收到无用的错误消息,一个像main.xml.out一样创建的奇怪文件,并且它不会运行。


#3楼

I had the same problem 我有同样的问题

  1. I entered Task manager -> find adb.exe -> end process 我进入任务管理器 - >找到adb.exe - >结束进程
  2. Go to the Android SDK tools directory in Command Prompt double click adb.exe 转到命令提示符下的Android SDK工具目录,双击adb.exe

That's all 就这样


#4楼

maydenec is correct (in my case...). maydenec是正确的(在我的情况下......)。 The file was moved. 该文件已被移动。

I even found this file: 我甚至找到了这个文件:

C:\Program Files (x86)\Android\android-sdk\tools\adb_has_moved.txt

Which explained this issue. 哪个解释了这个问题。

Suggestions in this file: 此文件中的建议:

  1. Install "Android SDK Platform-tools". 安装 “Android SDK Platform-tools”。
  2. Please also update your PATH environment variable to include the "platform-tools/" directory. 还请更新 PATH环境变量以包含“platform-tools /”目录。

#5楼

[2012-07-04 11:24:25 - The connection to adb is down, and a severe error has occurred. [2012-07-04 11:24:25 - 与adb的连接已关闭,并且发生了严重错误。
[2012-07-04 11:24:25 - You must restart adb and Eclipse. [2012-07-04 11:24:25 - 你必须重启adb和Eclipse。
[2012-07-04 11:24:25 - Please ensure that adb is correctly located at '/home/ASDK/platform-tools/adb' and can be executed [2012-07-04 11:24:25 - 请确保adb正确位于'/ home / ASDK / platform-tools / adb'并且可以执行

I realized the folder of the project in Eclipse was closed. 我意识到Eclipse中的项目文件夹已关闭。 I expanded the directory and the project launched. 我扩展了目录并启动了项目。 I know this may sound like a "no-brainer". 我知道这听起来像是“毫无疑问”。 I had the .java files open on the workspace, and that was enough to make me think the project was open. 我在工作区打开了.java文件,这足以让我觉得项目是开放的。


#6楼

I know this question has already been answered, but thought I might add that I found the problem to be folder permissions on my android-sdk directory. 我知道这个问题已经得到了解答,但我想我可能会补充一点,我发现问题是我的android-sdk目录下的文件夹权限。

I tested it out by granting Full Control to Everyone (dodgy, I know...), and the problem went away. 我通过向每个人授予完全控制权来测试它(狡猾,我知道......),问题就消失了。 I am not sure yet what the specific mix of permissions might be that it was looking for, but I assume some or other service in Eclipse didn't have execute permissions on adb.exe. 我不确定它正在寻找的特定权限组合是什么,但我认为Eclipse中的某些或其他服务没有对​​adb.exe的执行权限。 That said, I'm a complete noob to this - just wanted to put it out there in case someone else had some insights into this. 也就是说,我是一个完全的菜鸟 - 只是想把它放在那里以防其他人对此有所了解。

I am running Windows 7, 64-bit, 4.2.0 Eclipse, and 20.0.0v201206242043 ADT. 我正在运行Windows 7,64位,4.2.0 Eclipse和20.0.0v201206242043 ADT。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值