zoukankan      html  css  js  c++  java
  • Android 常遇错误解决方案

    遇到问题描述:

    运行android程序控制台输出

        [2012-07-18 16:18:26 - ] The connection to adb is down, and a severe error has occured.
        [2012-07-18 16:18:26 - ] You must restart adb and Eclipse.
        [2012-07-18 16:18:26 - ] Please ensure that adb is correctly located at 'D:javasdkplatform-toolsadb.exe' and can be executed.

    解决问题:

    在任务管理器中 kill掉adb 或者重启adb server,如果任务管理器就没有adb ,可能是某个程序占用了adb端口。于是按此思路查找。

    5037为adb默认端口 查看该端口情况如下:

           netstat -aon|findstr "5037"

          TCP    127.0.0.1:5037         0.0.0.0:0              LISTENING       6540

    发现6540占用了 5037端口,继续查看6540的task,发现是wandoujia  .如下所示

            tasklist|findstr "6540"

            wandoujia_daemon.exe          6540 Console                    1      4,276 K

    在任务管理器kill掉wandoujia_daemon.exe ,重启Eclipse,运行android程序,ok .

    1.报错: 
    BUILD FAILED 
    D:workspaceganjiuild.xml:144: The following error occurred while executing this line: 
    D:workspaceganjiuild.xml:271: Unable to delete file D:workspaceganji mpproguard mp.jar 
    解决: 
    已经开了一个模拟器了,无法重新编译,必须关闭一个。用于ant 


    2.报错: 
    The connection to adb is down, and a severe error has occured. 
    这个问题谁能解决啊 
    解决: 
    cmd跳到sdk tools文件路径下 
    adb kill-server 
    然后再adb start-server 

    3.报错: 
    The connection to adb is down, and a severe error has occured. 
    [2010-03-11 09:36:56 - HelloOPone] You must restart adb and Eclipse. 
    [2010-03-11 09:36:56 - HelloOPone] Please ensure that adb is correctly located at 'D:OPhoneSDK_1.5 
    platform-toolsadb.exe' and can be executed. 
    解决: 
    方法1.cmd中adb kill-server,然后adb -startserver 
    方法2.方法1不管用,那么在任务管理器中杀死adb.exe,然后重启Eclipse。 
    方法3.方法1和2都不管用,那么查看最后一句报错中:platform-tools中是否有adb.exe(我的错误就是在相关路径下面没有platform-tools文件夹 
    ,所以我选择新建一个文件夹,并且把tools中的文件全部复制到platform-tools中) 
    4.前面的方法试了还是不行的话,建议重新装一个系统,最好换个系统。有些大牛也说过:MS存在一些小问题[size=large][/size]

  • 相关阅读:
    转!idea 破解版 安装
    原!!自动备份 发布脚本
    原!linux脚本统计
    转!!mybatis xml 传值 if test判断
    转!mysql备份与还原数据库
    转!mysql 命令行下 通过DELIMITER临时改变语句分隔符 执行存储过程
    原!统计文件 包含关键字 数量
    原!mysql存储过程 批量导入数据
    转!!Linux 里的 2>&1 究竟是什么
    原!linux 监控 jar定时任务 挂了重启 脚本
  • 原文地址:https://www.cnblogs.com/xiaoerlang90/p/4105603.html
Copyright © 2011-2022 走看看