Tomcat. Unable to open debugger port

Hello,
Today, I want to debug web application, but occurs message windows with error:
Error running WebTomcat: Unable to open debugger port : java.lang.SocketException "Socket Closed"

Shreenshot attached.

Please help me, to detect problem reason, and solve them.



Attachment(s):
screenshot.PNG
6 comments
Comment actions Permalink

This is message from console window of IDEA. Is it a problem of IDEA or Tomcat? When I just run (not debug) it work correctly. Please help me.

cmd /c "C:\Program Files\Apache Group\Tomcat 4.1\bin\catalina.bat" run
Using CATALINA_BASE: C:\Documents and Settings\TuralM\.IntelliJIdea60\system\tomcat_Unnamed_c72cf5d93
Using CATALINA_HOME: C:\Program Files\Apache Group\Tomcat 4.1
Using CATALINA_TMPDIR: C:\Program Files\Apache Group\Tomcat 4.1\temp
Using JAVA_HOME: C:\Java\j2sdk1.4.2_07
FATAL ERROR in native method: No transports initialized
Transport dt_socket failed to initialize, rc = 509.
Disconnected from server

0
Comment actions Permalink

Hello Tasadar,

Looks like a problem of JDK.

This is message from console window of IDEA. Is it a problem of IDEA
or Tomcat? When I just run (not debug) it work correctly. Please help
me.

cmd /c "C:\Program Files\Apache Group\Tomcat 4.1\bin\catalina.bat" run
Using CATALINA_BASE: C:\Documents and
Settings\TuralM\.IntelliJIdea60\system\tomcat_Unnamed_c72cf5d93
Using CATALINA_HOME: C:\Program Files\Apache Group\Tomcat 4.1
Using CATALINA_TMPDIR: C:\Program Files\Apache Group\Tomcat 4.1\temp
Using JAVA_HOME: C:\Java\j2sdk1.4.2_07
FATAL ERROR in native method: No transports initialized
Transport dt_socket failed to initialize, rc = 509.
Disconnected from server



0
Comment actions Permalink

Hi, I've just upgraded IDEA from 6.0.4 to 6.0.5 and tried to debug plugin I am working at and it fails at the same exception (java.net.SocketException). When I attempt to debug the same plugin on version 6.0.4, there's no problem.

Here is the stack from debug:

"C:\Program Files\JetBrains\IntelliJ IDEA 6.0.5\jre\jre\bin\java" -classic -Xms256 -Xmx512 -XX:MaxPermSize=300M "-Xbootclasspath/p:C:/Program Files/JetBrains/IntelliJ IDEA 6.0.5\lib\boot.jar" "-Didea.config.path=C:\Documents and Settings\pavlas\.IntelliJIdea60\sandbox\config" "-Didea.system.path=C:\Documents and Settings\pavlas\.IntelliJIdea60\sandbox\system" "-Didea.plugins.path=C:\Documents and Settings\pavlas\.IntelliJIdea60\sandbox\plugins" -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=127.0.0.1:1653,suspend=y,server=n -Dfile.encoding=UTF-8 -classpath "C:\Program Files\JetBrains\IntelliJ IDEA 6.0.5\jre\lib\tools.jar;C:/Program Files/JetBrains/IntelliJ IDEA 6.0.5\lib\idea.jar;C:/Program Files/JetBrains/IntelliJ IDEA 6.0.5\lib\extensions.jar;C:/Program Files/JetBrains/IntelliJ IDEA 6.0.5\lib\openapi.jar;C:/Program Files/JetBrains/IntelliJ IDEA 6.0.5\lib\jdom.jar;C:/Program Files/JetBrains/IntelliJ IDEA 6.0.5\lib\log4j.jar;C:\Program Files\JetBrains\IntelliJ IDEA 6.0.5\lib\idea_rt.jar" com.intellij.idea.Main
Error occurred during initialization of VM
Warning: classic VM not supported; client VM will be used
Too small initial heap

I cannot run the plugin either, I always get this warning:
Error occurred during initialization of VM
Too small initial heap

Did I set up anything wrong?

Thanks for any help, Josef Pavlas.

0
Comment actions Permalink

I found out my problem was in some strange way caused by JVM parameters -Xms and -Xmx. I removed them from debugging settings and now it's OK.

0
Comment actions Permalink

Thanks. It's work for me

0
Comment actions Permalink

In my cause it was simple misstype. I have added JAVA_OPTS in catalina.sh like this:
export JAVA_OPTS="-Xmx1024m -Xms128m"

and of course it was wrong :). It should add the previous value of JAVA_OPTS (set by IntelliJ with debug port.. :)).
After correcting it to:
export JAVA_OPTS="-Xmx1024m -Xms128m $JAVA_OPTS"
everything works great.

hope this helps,
zgibek

0

Please sign in to leave a comment.