与 adb 的连接已断开,并且发生了严重错误

发布于 2024-10-17 16:54:42 字数 985 浏览 8 评论 0原文

可能的重复:
与 adb 的连接已关闭,并且发生严重错误

我目前正在尝试在最新版本的 Eclipse 中开发 Android 应用程序。当我尝试构建并运行时,出现以下信息:

[2011-02-17 17:08:03 - <ProgramName>] The connection to adb is down, and a severe error has occured.
[2011-02-17 17:08:03 - <ProgramName>] You must restart adb and Eclipse.
[2011-02-17 17:08:03 - <ProgramName>] Please ensure that adb is correctly located at 'C:\<sdk-directory>s\platform-tools\adb.exe' and can be executed.

现在,我已经更新了 ADT 插件,我拥有最新版本的 Android SDK; adb.exe其实就在platform-tools目录下,可以执行。我已经尝试了在 Google 上找到的所有内容:

  • 我尝试了 adb Kill-server 和 adb start-server
  • 我尝试在没有启动模拟器的情况下运行它
  • 我的 PATH 中有给定的目录(我尝试使用中的平台工具路径,我尝试在我的路径中同时包含平台工具和工具)。

注意:我运行的是 Windows 7。此外,我之前曾在 Eclipse 中测试过应用程序。自从升级 SDK 以来,这个错误对我来说是新的。

Possible Duplicate:
The connection to adb is down, and a severe error has occured

I am currently trying to develop an application for Android in the latest release of Eclipse. When I try to build and run, the following comes up:

[2011-02-17 17:08:03 - <ProgramName>] The connection to adb is down, and a severe error has occured.
[2011-02-17 17:08:03 - <ProgramName>] You must restart adb and Eclipse.
[2011-02-17 17:08:03 - <ProgramName>] Please ensure that adb is correctly located at 'C:\<sdk-directory>s\platform-tools\adb.exe' and can be executed.

Now, I have updated the ADT plugin, I have the latest version of the Android SDK; adb.exe is, in fact, in the platform-tools directory and can be executed. I've tried everything I found on Google:

  • I tried adb kill-server and adb start-server
  • I tried to run it with an without an emulator started
  • I have the given directory in my PATH (I tried with just the platform-tools in the path and I tried with having both platform-tools and tools in my PATH).

Notes: I am running Windows 7. Also, I have previously tested apps in Eclipse. This error is new to me since upgrading the SDK.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(11

三生池水覆流年 2024-10-24 16:54:42

我刚刚遇到了同样的问题并修复它,我打开任务管理器并终止了 adb.exe 进程,然后重新启动 Eclipse。

I just got the same problem and to fix it, I opened the task manager and killed the adb.exe process, then I restarted Eclipse.

想念有你 2024-10-24 16:54:42

全部重装???决不!只需从环境变量中将 SDK 工具和平台工具的路径添加到类路径中。然后重新启动 Eclipse。

其他方式转到设备 ->重置 adb,或者只需打开任务管理器并终止 adb.exe 进程。

Reinstall everything??? no way! just add the path to SDK tools and platform tools in your classpath from Environment Variables. Then restart Eclipse.

other way go to Devices -> Reset adb, or simply open the task manager and kill the adb.exe process.

纵情客 2024-10-24 16:54:42

我重新启动了 Eclipse 并执行了 Project -> 干净 ->选择您的项目
其中之一解决了我的 adb 问题

[2011-12-31 10:50:45 - HelloAndroid] Android Launch!                      good

[2011-12-31 10:50:45 - HelloAndroid] adb is running normally.             good

[2011-12-31 10:50:45 - HelloAndroid] Could not find HelloAndroid.apk!     bad

感谢您的帮助。继续下一个问题(叹气)

I restarted eclipse and did the Project -> Clean -> select your project
One of them fixed my problem with adb

[2011-12-31 10:50:45 - HelloAndroid] Android Launch!                      good

[2011-12-31 10:50:45 - HelloAndroid] adb is running normally.             good

[2011-12-31 10:50:45 - HelloAndroid] Could not find HelloAndroid.apk!     bad

Thanks for the help. On to the next problem (sigh)

还如梦归 2024-10-24 16:54:42

听起来对我的问题有点熟悉:在正确的路径下找不到aapt

我需要清理所有打开的项目才能使其再次工作......

Sounds a bit familiar with my problem: aapt not found under the right path

I needed to clean all open projects to get it working again...

别把无礼当个性 2024-10-24 16:54:42

我和你有完全相同的问题。经过两天的思考为什么会出现这种情况,我终于通过将 adb.exe 从 COMODO 防病毒软件的不可靠软件列表移动到其可靠软件列表来解决这个问题。当时我已经尝试了至少5种措施来让adb工作,包括以上......

I had exactly the same problem with you. And after two days wondering why this occurs to me, I finally got through this by moving the adb.exe from the unreliable software list of the COMODO anti-virus to its reliable software list. At that time, I had tried at least 5 kinds of measures to make the adb work, including all above...

⊕婉儿 2024-10-24 16:54:42

上次更新 ADT 插件时,adb.exe 和 Eclipse 也遇到了类似的问题。解决方案是以管理员身份运行 Eclipse 并重新安装 ADT。

I had a similar problem with adb.exe and Eclipse last time I updated ADT plugin. The solution was to run Eclipse as administrator and reinstall ADT.

神经大条 2024-10-24 16:54:42

问题可能出在您的防火墙或防病毒软件上。

  1. 禁用所有网络连接
  2. 禁用防火墙
  3. 禁用防病毒软件

确保它们全部禁用。

在 Eclipse 中运行您的脚本。如果有效,那么 2 和 3 可能就是罪魁祸首。对我来说,它是 comodo 防火墙。我为 Adb.exe 创建了一个过滤器

The problem might be with your firewall or antivirus.

  1. Disable all network connection
  2. Disable firewall
  3. Disable Antivirus

Make sure they all disabled.

Run your script in Eclipse. If it works, then 2 and 3 might be the culprit. For me, it was comodo firewall. I created a filter for Adb.exe

疯到世界奔溃 2024-10-24 16:54:42

对我来说,以下方法有效:

  1. 从任务管理器中杀死 adb.exe

  2. 以管理员身份重新启动 Eclipse

  3. 对于我的应用程序,目标是 Google API 级别 10.. 我转到 Window-> AVD 管理器和“Google API 级别 10”条目有一个损坏的而不是绿色勾号 - 因此我只需单击该条目并单击“修复”按钮,问题就得到修复

(可能只有上面的 3 个..)

For me the following worked:

  1. Kill adb.exe from Task Manager

  2. Restart Eclipse as administrator

  3. For my app, the target was Google APIs level 10.. I went to Window-> AVD Manager and the entry for "Google APIs level 10" had a broken instead of a green tick - so I just clicked the entry and clicked the "repair" button and problem was fixed

(It was probably only 3 above..)

软糖 2024-10-24 16:54:42

从您发布的内容来看,假设这不是拼写错误,Eclipse 正在查找 C:\s\platform-tools...

如果是这种情况,那么您应该检查 Eclipse 的 Window/Preferences SDK 位置的 /Android 选项。也许你的设置为“C:\ s”。您无法将其编辑为这样的值而不导致错误,但也许它已以某种方式损坏。

Judging from what you've posted, and assuming it's not a typo, Eclipse is looking in C:\s\platform-tools...

If that's the case, then you should check Eclipse's Window/Preferences/Android option for the SDK Location. Maybe yours is set to "C:\s". You can't edit it to be a value such as that without causing an error, but maybe it's got corrupted somehow.

浮华 2024-10-24 16:54:42

如果您使用 JUnit 而不是 Android JUnit 运行测试项目,也可能会出现此错误。当然,解决方案就是改变运行方式。

It's also possible to get this error if you are running the test project using JUnit instead of Android JUnit. Naturally, the solution is just to change how you run it.

我是男神闪亮亮 2024-10-24 16:54:42

与 adb 的连接已断开,并且发生了严重错误。

[2011-12-19 11:45:09 - RayhReport] You must restart adb and Eclipse.
[2011-12-19 11:45:09 - RayhReport] Please ensure that adb is correctly located at 'D:\android-sdk-windows\tools\adb.exe' and can be executed.

当您转到 D:\android-sdk-windows\tools\adb.exe 路径时,您会看到文本文件,文件名是“adb_has_moved”,这意味着您的 adb.exe 移动到平台工具,复制 adb.exe 并粘贴到工具文件夹中并运行它。我确信它有效。

The connection to adb is down, and a severe error has occured.

[2011-12-19 11:45:09 - RayhReport] You must restart adb and Eclipse.
[2011-12-19 11:45:09 - RayhReport] Please ensure that adb is correctly located at 'D:\android-sdk-windows\tools\adb.exe' and can be executed.

When you go to D:\android-sdk-windows\tools\adb.exe path then you see the text file,the name of file is "adb_has_moved" thats means your adb.exe is moved to platform-tools copied down the adb.exe and paste in tools folder and run it. I'm sure it works.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文