Can't Bind To Local 8700 For Debugger Android Studio

  1. Can't Bind To Local 8700 For Debugger
  2. Can't Bind To Local 8700 For Debugger Android Studio 2017
  3. Can't Bind To Local 8700 For Debugger Android Studio Free
  4. Can't Bind To Local 8700 For Debugger Android Studio Download
  5. Can't Bind To Local 8700 For Debugger Android Studio Free

I cannot attach the debugger in Android Studio while running debug on a phone.

猜您在找 Android(java)學習筆記133:Eclipse中的控制台不停報錯Can't bind to local 8700 for debugger android Can't bind to local 86XX for debugger 解決svnserve: Can't bind server socket: Address already in use Angular 報錯 Can't bind to 'formGroup' since it isn't a known property of 'form' 解決ERROR 2002 (HY000): Can't. 2014-06-26 15:50:56 - ddms Can't bind to local 8700 for debugger一、BUG环境:macbookpro+eclipse+adt+adbWireless(MBP共享网络给Android手机)二、影响:在下图中LogCat和Console标签页之间来回跳转,无法安逸查看LOG数据。.

I’m currently using a Samsung S4, running Android 4.4.4 (but have tried an S5, S6, S7, and Moto E phone on various Android versions). It times out when I try to run it with either of the following errors:

May 17, 2018 Android Studio Unable to open debugger port (localhost:8700): java.net.SocketException 'Connection reset' #607 Open guitar9 opened this issue May 17, 2018 14 comments.

I/System.out: Sending WAIT chunk
W/ActivityThread: Application is waiting for the debugger on port 8100…

Can't Bind To Local 8700 For Debugger

Can

Or

Can

failed to open debugger port localhost:8600 java.net.ConnectException “connection refused”

and the App says:

Waiting For Debugger
Application (process ) is waiting for the debugger to attach.
Force Close

Android Studio version:

Android Studio 2.2.2
Build #AI-145.3360264, built on October 18, 2016
JRE: 1.8.0_112-release-b05 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o

Mac version:

10.11.6 (15G1004)

I can successfully connect and run the application, I just can’t get the debugger to attach when I do Run > Debug App > select the connected phone > OK.

Can

I have been able to run the app in debug on other computers (both Windows and Mac) with the same phones.

Various approaches I have tried from hours of debugging and online searching:

  1. Invalidate Caches/Restart Android studio

  2. Bluestacks 1 android emulator for pc. Check for anything else running on ports 8100, 8600, 8601, etc., nothing comes back when I run the following from bash:

    studio 6282 peter 125u IPv4 0x973c7e31bda641ab 0t0 TCP 192.168.1.16:64022->ip-166-62-27-181.ip.secureserver.net:asterix (SYN_SENT)
    $ lsof -i :8601
    $
    $ # after Android studio fails to attach the debugger
    $ lsof -i :8100
    $ lsof -i :8600
    $ lsof -i :8601
    $

  3. Run Tools > Android > Android Device Monitor – it shows my device, but I can’t run Android Device Monitor while I’m trying to debug the app, it says, “Monitor will be closed to enable ADB integration. Continue?” I haven’t found anything useful here.

  4. Searching for and killing adb processes

  5. Restart Android studio

  6. Restart my computer

  7. Update Java JDK from the Oracle website—however, I’m not sure why Android Studio still says, “JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o”

  8. Completely uninstall and reinstall android studio – e.g., https://stackoverflow.com/a/18458893/376489 – weirdly, I think this worked for one run of the debugger and then not again…

  9. Tried Run > Attach debugger to Android Process – this didn’t help

  10. Tried running:

  11. Tried unchecking Run > Edit Configurations > Run/Debug Configurations > Skip installation if APK has not changed

  12. Check System Preferences > Security & Privacy > Firewall – this is turned off

  13. Update 1: tried revoking permissions on the phone as well as restarting it

  14. Update 1: muted all breakpoints Android Studio

Are there any other ideas for what might be going wrong or anything meaningful in the details I added above?

How to&Answers:

Quite embarrassing, but it looks like some time ago I had entered an ip address into my /etc/hosts file to test something as localhost and never removed it. I found a comment on another post saying to check that the following is in your /etc/hosts:

Can't Bind To Local 8700 For Debugger Android Studio 2017

Upon commenting out that spurious line, the debugger is now working. Given I have a dozen or so other IPs in that file (so I can more easily test remote hosts with a friendly name), I must have not noticed this one at the bottom. I think a more foolproof approach to verifying if this is the problem or not is to ping localhost and verify that it resolves to the ip address of 127.0.0.1, e.g.,

Great comments and suggestions from other folks here too, thanks!

Answer:

I just experienced the same issue. It seems, as if Android Studio Version 2.2 has some issues with a non-attaching debugger as you can see for example here and here.

In my case the following helped:

  • Remove the launch profile for your app by going to Run -> Edit Configurations… and removing the profile there. Don’t forget to hit the OK button after you have removed the profile. 🙂
  • Create a new launch profile from scratch by again going to Run -> Edit Configurations…, hitting the + button, selecting an Android App launch profile and selecting your start module. The other default values of the profile were just fine.

Hope this helps you as well.

Answer:

1.try cleaning project Build->clean project

2.do file->Invalidate/cache restart
if above not helps you.

3.try to change the data cable you are using to connect your phone.

if nothing above helps, install Android wifi ADB plugin and try to do debug over wifi.

Local

Answer:

I am using a real device. Simply deleting the app on the device, and then running from Android Studio solved this issue.

It seems Android Studio had trouble with overwriting the file that was already on the phone.

Answer:

I also got same error and this thing worked for me

Then you will get this output

Answer:

Support for a true debug build. Developers no longer need to add the android:debuggable attribute to the tag in the manifest — the build tools add the attribute automatically. In Eclipse/ADT, all incremental builds are assumed to be debug builds, so the tools insert android:debuggable=”true”. When exporting a signed release build, the tools do not add the attribute. In Ant, a ant debug command automatically inserts the android:debuggable=”true” attribute, while ant release does not. If android:debuggable=”true” is manually set, then ant release will actually do a debug build, rather than a release build.

Can

In my case i struggling this issue with 5 hour and found that the

minifyEnabled true is the main culprit so change
minifyEnabled false work for me

My app build.gradle file look like

Answer:

I have the opposite problem with Android Studio 3.3, trying to debug a wi-fi-connected phone.

After selecting the device in Android Studio, I receive the following message:

Error running ‘app’: Unable to open debugger port (localhost:8600):
java.net.ConnectException “Connection refused: connect”

I also have IPV-6 enabled on my network.

Can't Bind To Local 8700 For Debugger Android Studio Free

The issue is that “localhost” resolves to ::1 on my machine by default, but ADB studiously binds explicitly to 127.0.0.1. I happen to know this because I spent the day trying to make ADB connect to emulators running on a remote machine (not since Android 4.4 unfortunately.

To solve the problem, add the following line to windowssystem32driversetchosts:

127.0.0.1 localhost

Answer:

Try using below commands on terminal-

  1. adb kill-server

  2. adb start-server

It works well.

Can't Bind To Local 8700 For Debugger Android Studio Download

Answer:

Simply not using my google pixel 1st gen and using my new Nokia 7 plus fixed this issue :).

Answer:

This problem was driving me crazy for about 2 weeks. What finally fixed it for me was changing “auto” to “java” in the debugger process selection window like this:

Answer:

At first i tried all the above ways, did not help.
I have two computers with same settings.
But at one worked at other error.
It’s given me an idea that it can be “hardware” problem.
I switched USB to other slot with USB3.0 and used short cable and
WOW it began work.
I suggest there some delay in USB2.0 (polling), therefore process begin out of synch.

Can't Bind To Local 8700 For Debugger Android Studio Free

Tags: .net, android, androidjava, debugging, exception