Pankaj Kumar
Pankaj Kumar

Reputation: 255

Debugging remote application in eclipse?

I am trying to debug my remote application. In one of my project documents I found these steps.

I followed these steps, and in eclipse I got "waiting for vm to co... port 8000...".

It never ends... I Googled it but couldn't find the resolution.

Upvotes: 2

Views: 4521

Answers (3)

Robin Green
Robin Green

Reputation: 33063

It sounds like both Eclipse and the JVM are each waiting for the other one to connect to it. I think you need to select Socket Attach in Eclipse, not Socket Listen.

Upvotes: 1

Subin Sebastian
Subin Sebastian

Reputation: 10997

suppose your remote container is running at 192.0.0.0, then you have to add debug parameters to jvm in remote server.

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

Then in your local machine run eclipse. In local machine start eclipse, Run->Debug Configurations... Choose Remote Java Application from the list. Click on the New launch configuration button in the upper left. Name the new configuration. Change the Connection Type to Standard (Socket Listen). Make sure under connection properties you give server host as 192.0.0.0 and port as 8000 and Click on Apply, then Debug.

Upvotes: 1

Ahmet Karakaya
Ahmet Karakaya

Reputation: 10139

Try the following JVM configuration,

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

Upvotes: 1

Related Questions