1

I want to remote debug an application. My tomcat server is running in a Vm. I am trying to connect to it to debug. How can I connect to it? NOTE: I am trying to do this in windows machines.

Already tried the solution mentioned in.

How to debug a Tomcat 7.x/8.x webapp locally with IntelliJ Community (free) version in Linux?. But after following the steps, I am getting:

Error running 'Local Apache Tomcat': Unable to open debugger port (localhost:12000): java.net.ConnectException "Connection refused: connect"
Error running 'Local Apache Tomcat': Unable to open debugger port (10.194.43.79:12000): java.net.ConnectException "Connection refused: connect"

Made sure the jdk that I am mentioning in settings. And the one which is installed in vm machine, It's same.

I am able to ping the machine.

I've tried to connect to it with tomcat which is running on my machine. It's not working.

Acc. to How to debug a Tomcat 7.x/8.x webapp locally with IntelliJ Community (free) version in Linux?

I should've received:

Connected to the target VM, address: '10.194.43.79:12000', transport: 'socket'

Instead it's:

Error running 'Local Apache Tomcat': Unable to open debugger port (10.194.43.37:12000): java.net.ConnectException "Connection timed out: connect"
vishalK
  • 13
  • 7
  • Is your port you are trying to connect is same as you have provided in your JAVA_OPTS? – Nitin Zadage Jun 20 '19 at 07:23
  • Yes. CATALINA_OPTS = "$CATALINA_OPTS -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=12000" I went catalina opts and have triedn JAVA OPTS as well. – vishalK Jun 20 '19 at 07:26
  • when I put his : set "JAVA_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=12000" in catalina.bat file in my local machine. Then I am able to connect. Connected to the target VM, address: 'localhost:12000', transport: 'socket' But not able to do this with my VM. – vishalK Jun 20 '19 at 08:07

0 Answers0