tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From D├ęsilets, Alain <Alain.Desil...@nrc-cnrc.gc.ca>
Subject Re: Can't start Tomcat in debug mode
Date Mon, 16 Jul 2018 12:56:19 GMT
Thx Luis,

> /Library/Tomcat/bin/catalina.sh jpda start should be good enough. If you
> have a look at the tomcat command line process are the JPDA options
>  enabled? E.g.:
>   
>    $ $CATALINA_HOME/bin/catalina.sh jpda start
>    
>    $ ps -ef | grep --color dt_socket
>    lurodrig 13522  2883  6 13:58 pts/5    00:00:04
>    .../jdk1.8.0_162/bin/java...
>    -agentlib:jdwp=transport=dt_socket,address=localhost:8000,server=y,suspend=n
>    ... org.apache.catalina.startup.Bootstrap start
  
This is what I get:

  501  2323     1   0  8:31am ttys001    0:25.08 /Library/Java/JavaVirtualMachines/jdk1.8.0_102.jdk/Contents/Home/bin/java

[...] -agentlib:jdwp=transport=dt_socket,address=8000,server=y,suspend=n [...] org.apache.catalina.startup.Bootstrap
start
  
>    In the catalina.out you should see something like: Listening for transport
>    dt_socket at address: 8000
    
Yep, I get it.


    
>    lurodrig@:tomcat-9-0-5-installation$ lsof -i:8000
>    COMMAND   PID     USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
>    java    13522 lurodrig    4u  IPv4 450991      0t0  TCP localhost:8000
>    (LISTEN)
  
Gives me this

	java    2323 desilets    5u  IPv4 0xad510ad86ad41671      0t0  TCP *:irdmi (LISTEN)
  
which seems to indicate that Tomcat is NOT listening on locahost, but on something called
*:irdmi. Not sure that this matters, because from what I can read on the net, *:irdmi corresponds
to port 8000.


>    lurodrig@:tomcat-9-0-5-installation$ lsof -i:8080
>    COMMAND   PID     USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
>    java    13522 lurodrig   51u  IPv6 450993      0t0  TCP *:http-alt (LISTEN)

Gives me this:

 	java    2323 desilets   61u  IPv6 0xad510ad8630f7d61      0t0  TCP *:http-alt (LISTEN)

Again, I believe *:http-alt is just an alias for  8080, so it doesn't seem to matter.

Note that if I start with 'catalina.sh start' (i.e. no jpda), I get *:http-al for 'lsof -8080'
 and nothing for 'lsof -8000'.

>    Hope it helps,
  
So far, no. But I appreciate the effort. Any other ideas?
  
>    ps: a HTTP request against the debug port will print this message in the
>    catalina.out Debugger failed to attach: handshake failed - received >GET /
>    HTTP/1.1< - expected >JDWP-Handshake<
    
 Yep, I get that message when running with jpda

Alain
 

Mime
View raw message