百度了一下,答案都千篇一律,提示关掉防火墙,重启adb,但是我试了,对我都没有效果。
后来在http://stackoverflow.com上面找到了这个问题,按照建议做,果然好了。
疑问:
虽然暂时没有问题了,但是我还是不明白为什么会这样,期待有经验的的高手们路过的时候给点参考。
下面是http://stackoverflow.com上的问题和解决方法,可能不一定能解决所有的该类问题,但是贴出来,希望有点帮助。
问题:
I have a problem, when I want to start developing applications for android, I did everything like in manualhere but after installing ADT Plugin in Eclipse I am still getting this error :
[2011-12-29 14:34:56 - ddms] Failed to initialize Monitor Thread: Unable to establish loopback connection
then, if I try to run an application this appear :
解决方法:[2011-12-29 14:41:42 - TestApp] ------------------------------ [2011-12-29 14:41:42 - TestApp] Android Launch! [2011-12-29 14:41:42 - TestApp] Connection with adb was interrupted. [2011-12-29 14:41:42 - TestApp] 0 attempts have been made to reconnect. [2011-12-29 14:41:42 - TestApp] You may want to manually restart adb from the Devices view.
No need to turn off tredo interface: simply add -Djava.net.preferIPv4Stack=true ineclipse.ini:
openFile -vmargs -Djava.net.preferIPv4Stack=true