Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to enable remote debugging for an Eclipse Application?

Im trying to enable remote debugging for an eclipse plugin project, for the purpose of using IntelliJ IDEA as a debugger.

The steps I've taken so far:

  1. Launch Eclipse.
  2. Run -> Debug Configurations...
  3. Create a new "Eclipse Application" (as to launch a local workspace which loads the plugin).
  4. Add -Xdebug -Xrunjdwp:transport=dt_socket,address=1044,server=y,suspend=n to VM arguments.
  5. Press the Debug button.

I get the following error:

ERROR: Cannot load this JVM TI agent twice, check your java command line for duplicate jdwp options. Error occurred during initialization of VM agent library failed to init: jdwp

What steps should I be taking to get IntelliJ IDEA to be able to debug an Eclipse Plugin running in a runtime workspace?

enter image description here

like image 665
Pétur Ingi Egilsson Avatar asked Oct 27 '25 15:10

Pétur Ingi Egilsson


1 Answers

  • Run -> Debug Configurations...
  • Add -Xdebug -Xrunjdwp:transport= dt_socket,address=1044,server=y,suspend=n to VM arguments.

This is redundant. Using a debug configuration already starts the application with the eclipse debugger attached to the process. Start it as a run configuration instead if you want to enable debugging through a server socket.

You can then create an additional "remote java application" debug configuration to attach to that socket.

like image 54
the8472 Avatar answered Oct 29 '25 03:10

the8472



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!