title: Unable to start a tomcat debug session from Eclipse
body: <p>I'd like to start a Tomcat debug session on my remote host from Eclipse, but it fails with this error:</p>
  
  <pre><code>Failed to connect to remote VM
  com.sun.jdi.connect.spi.ClosedConnectionException
  </code></pre>
  
  <p>My Tomcat is, I think, correctly configured to received debug session on port 8000:</p>
  
  <pre><code>tomcat   18771     1  1 17:18 ?        00:00:16 /usr/lib/jvm/java/bin/java -Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n -Djava.rmi.server.hostname=10.30.0.17 -Dcatalina.ext.dirs=/usr/share/tomcat5/shared/lib:/usr/share/tomcat5/common/lib -Djavax.sql.DataSource.Factory=org.apache.commons.dbcp.BasicDataSourceFactory -Djava.endorsed.dirs=/usr/share/tomcat5/common/endorsed -classpath /usr/lib/jvm/java/lib/tools.jar:/usr/share/tomcat5/bin/bootstrap.jar:/usr/share/tomcat5/bin/commons-logging-api.jar:/usr/share/java/mx4j/mx4j-impl.jar:/usr/share/java/mx4j/mx4j-jmx.jar -Dcatalina.base=/usr/share/tomcat5 -Dcatalina.home=/usr/share/tomcat5 -Djava.io.tmpdir=/usr/share/tomcat5/temp org.apache.catalina.startup.Bootstrap start
  </code></pre>
  
  <p>There is a firewall between my PC and the remote server, but the port is well opened, as I can see these packets with <code>tcpdump</code> on the server:</p>
  
  <pre><code>17:41:17.110977 IP X.X.X.X.57010 &gt; Y.Y.Y.Y.irdmi: S 868833744:868833744(0) win 8192 &lt;mss 1460,nop,wscale 8,nop,nop,sackOK&gt;
  17:41:17.111183 IP Y.Y.Y.Y.irdmi &gt; X.X.X.X.57010: S 3571247457:3571247457(0) ack 868833745 win 5840 &lt;mss 1460,nop,nop,sackOK,nop,wscale 7&gt;
  17:41:17.112624 IP X.X.X.X.57010 &gt; Y.Y.Y.Y.irdmi: . ack 1 win 256
  17:41:19.113216 IP Y.Y.Y.Y.irdmi &gt; X.X.X.X.57010: F 1:1(0) ack 1 win 46
  17:41:19.114246 IP X.X.X.X.57010 &gt; Y.Y.Y.Y.irdmi: P 1:15(14) ack 1 win 256
  17:41:19.114279 IP Y.Y.Y.Y.irdmi &gt; X.X.X.X.57010: R 3571247458:3571247458(0) win 0
  </code></pre>
  
  <p>The only message writtent in Tomcat logs is
      Debugger failed to attach: timeout during handshake</p>
  
  <p>I can't figure out what's wrong dispite informations I found on the web.</p>
  
  <p>Can anyone can help me?</p>
  
  <p>My server: RHEL 5.9, Tomcat 5.5, java 1.6</p>
  
  <p>Regards,
  Robert</p>