Can't get Eclipse to listen for debugger connections [message #1723630] |
Tue, 16 February 2016 16:26  |
Eclipse User |
|
|
|
I've used Eclipse as a remote debugger many times. I've done this with either local or remote target processes.
I've also successfully connected from a remote debugger to a test eclipse instance launched from another eclipse instance.
What I'm now trying to do is launch a normal eclipse instance so that the remote debugger can connect to it, and step through some code that Eclipse is executing.
When I attempt the connection, it just says "Connection refused".
Just so it's clear, I have instance "debugger" running on my laptop. I have the "target" instance running on a VM on the host. I've had no trouble launching instance "test" from the "target" instance, and connecting "debugger" to "test". I'm now trying to connect "debugger" to "target", instead of "test". I've even used the same port number that worked for "debugger" to "test" (the "test" instance isn't running when I try this).
I'm following the instructions from this: https://wiki.eclipse.org/How_to_report_a_deadlock#Remote_Debug_Connection .
My resulting command line is just this:
<pathtoeclipsedir>/eclipse -showlocation -vmargs "-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000"
When I first ran this, I then tried to connect from the debugger. It said "Connection refused". After some thought I then ran "netstat -a | grep 8000" on the VM. Nothing there. I then ran "ps -augwwwx | grep java", which showed that the "java" command line had the "-Xdebug" parameters that I added.
Here is the command line that "ps -augwwwx" shows (with some paths elided):
<pathtojre>/bin/java -Doomph.update.url=http://download.eclipse.org/oomph/updates/milestone/latest -Doomph.redirection.index.redirection=index:/->http://git.eclipse.org/c/oomph/org.eclipse.oomph.git/plain/setups/ -Dosgi.requiredJavaVersion=1.8 -Xms256m -Xmx1024m -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000 -jar <pathtoeclipse>//../../../.p2/pool/plugins/org.eclipse.equinox.launcher_1.3.200.v20151021-1308.jar -os linux -ws gtk -arch x86_64 -showsplash -launcher <pathtoeclipse>/eclipse -name Eclipse --launcher.library <pathtoeclipse>//../../../.p2/pool/plugins/org.eclipse.equinox.launcher.gtk.linux.x86_64_1.1.300.v20151013-1129/eclipse_1612.so -startup <pathtoeclipse>//../../../.p2/pool/plugins/org.eclipse.equinox.launcher_1.3.200.v20151021-1308.jar --launcher.appendVmargs -exitdata 4f8001 -install <pathtoeclipse> -product org.eclipse.epp.package.java.product -showlocation -vm <pathtojre>/bin/java -vmargs -Doomph.update.url=http://download.eclipse.org/oomph/updates/milestone/latest -Doomph.redirection.index.redirection=index:/->http://git.eclipse.org/c/oomph/org.eclipse.oomph.git/plain/setups/ -Dosgi.requiredJavaVersion=1.8 -Xms256m -Xmx1024m -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000 -jar <pathtoeclipse>//../../../.p2/pool/plugins/org.eclipse.equinox.launcher_1.3.200.v20151021-1308.jar
So this shows that the "-Xdebug" params are on the command line, but Eclipse doesn't appear to be listening on the port.
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.05405 seconds