为什么MonkeyRunner.waitForConnection()错误"亚洲开发银行ADB拒绝端口转发命令:无法绑定套接字"亚洲、绑定、端口、开发银行

由网友(骑猪去兜风)分享简介:当我试图让与MonkeyRunner的设备我得到这个消息:             newdevice = MonkeyRunner.waitForConnection()      110804 17:35:28.561:S [主] [com.android.monkeyrunner.adb.AdbMonkeyDev...

当我试图让与MonkeyRunner的设备我得到这个消息:

            

newdevice = MonkeyRunner.waitForConnection()      110804 17:35:28.561:S [主] [com.android.monkeyrunner.adb.AdbMonkeyDevice]亚洲开发银行ADB拒绝端口转发命令:无法绑定套接字      110804 17:35:28.561:S [主] [com.android.monkeyrunner.adb.AdbMonkeyDevice] com.android.ddmlib.AdbCommandRejectedException:无法绑定套接字

      

我正在从Windows XP中的命令行使用JDK 1.6.0_26,Python的2.7.2和Android SDK monkeyrunner.bat 11 ADB设备显示了我的USB设备。

解决方案

我也曾经碰到过这个问题,但杀死并重新启动服务器ADB解决din't问题。我曾与下面的程序解决它。

开启命令提示符以下命令来运行netstat的-ano它列出了所有PID和端口号。记下PID端口12345 听转到任务管理器 - >进程选项卡从查看 - >选择Coloumns勾选PID字段。具有PID在previous一步指出现在终止进程。

现在的MonkeyRunner进行进一步。

注意:

12345端口从AdbChimpDevice.java在chimpchat.jar识别位于

.. Android的SDK-WINDOWS 工具 lib目录 chimpchat.jar

When I try to get a device with MonkeyRunner I get this message:

newdevice = MonkeyRunner.waitForConnection() 110804 17:35:28.561:S [main] [com.android.monkeyrunner.adb.AdbMonkeyDevice] Adb rejected adb port forwarding command: cannot bind socket 110804 17:35:28.561:S [main] [com.android.monkeyrunner.adb.AdbMonkeyDevice]com.android.ddmlib.AdbCommandRejectedException: cannot bind socket

I'm running monkeyrunner.bat from the commandline in windows Xp with JDK 1.6.0_26, Python 2.7.2, and Android SDK 11. adb devices shows my USB device.

解决方案

I also had come across this problem but killing and restarting the adb server din't solve the issue. I have solved it with below procedure

open command prompt and run below command netstat -ano This lists all PID and port numbers. Make a note of PID listening on port 12345 Go to task manager->Processes tab and from View->Select Coloumns Tick the PID field. Now kill the process with PID noted in previous step.

Now the MonkeyRunner proceeds further.

Note:

12345 port is identified from AdbChimpDevice.java in chimpchat.jar located in

..android-sdk-windowstoolslibchimpchat.jar

阅读全文

相关推荐

最新文章