General discussion


Bad documentation for remote debugging with Java 1.5

By jean-simon.s.larochelle ·
I'm I the only one finding the documentation for remote debugging to be very bad. I couldn?t find the simple recipe to use remote debugging anywhere on the Web (yes I looked on Sun's Web site).
Whatever happened to the good old 1.4 recipe (using -Xdebug and -Xrunjdwp on the application VM side and the corresponding parameters on the debugger side).
If someone knows the recipe (parameters on the application VM side and debugger side) to do the equivalent with 1.5 I sure would appreciate reading it.

Thanks in advance

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Comments

Collapse -

Some ole Same Ole

by nick In reply to Bad documentation for rem ...


I still use the following:


and it works fine with 1.5. I have done the same from a server and batch process and perfomr remote debugging through eclipse just like always.


Collapse -

Thanks Nick

by jean-simon.s.larochelle In reply to Some ole Same Ole

That's exactly what I was looking for.

I probably skip over it while looking at the documentation. Maybe I'm getting too old for this


Collapse -

Bad documentation for remote debugging with Java 1.5

by pauln In reply to Bad documentation for rem ...

I had to do a bit of fiddling to get mine to work in 1.5.

I'm using these switches on the application side (note this is on a Windows machine)

-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=1441

I've used the NetBeans, Eclipse and JDeveloper debuggers successfully with this - just ensure the transport is the same (dt_socket in this example) and the port is the same (1441 in this example)

I don't know of any good documentation on this sorry.


Collapse -

Thanks Paul however

by jslarochelle In reply to Bad documentation for rem ...

the -Xdebug and other options mentioned in my original post are nonstandard and in some cases deprecated (-Xdebug starting with 1.5).
With 1.5 the recommended parameter to use is the
-agentlib and associated parameters (see response by Nick for an example). And check the Java.exe documentation for details.
I knew about -Xdebug and associated parameters and I had used those in the past however when I saw in the documentation that the -Xdebug was deprecated in 1.5 I wanted to get information about the correct parameters to use and this is what frustrated me because while I could find a lot of detailed and low-level information about the new APIs (JVMTI versus JVMDI, etc...) I just could not find a single concrete example of a command line that I could use.
One thing that didn't help is the fact that I was probably subconciously looking for a switch with something like "debug" in it and -agentlib just did not register.

Thanks again for your response.

Collapse -

Official sites of interest

by Tarzanek In reply to Bad documentation for rem ...
Collapse -

Thanks Taz at last the link I was looking for

by jslarochelle In reply to Official sites of interes ...

and this should be useful to anyone trying to use the new parameters and switches.
We just could not put our fingers on this page when we did our search.
Using those links now anyone trying to use these VM options can go to the source and get the details.

Thanks again!

Collapse -

Thank you everyone

by jslarochelle In reply to Bad documentation for rem ...

I think that there is now enough information in this thread for anyone wanting to do remote debugging in Java 1.5 to get started.

Have fun programming in Java and good debugging.


Related Discussions

Related Forums