tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Johnny Kewl" <j...@kewlstuff.co.za>
Subject Re: jstack and Tomcat 6 on Windows
Date Fri, 19 Sep 2008 22:36:45 GMT

----- Original Message ----- 
From: "André Warnier" <aw@ice-sa.com>
To: "Tomcat Users List" <users@tomcat.apache.org>
Sent: Friday, September 19, 2008 11:42 PM
Subject: Re: jstack and Tomcat 6 on Windows


> André Warnier wrote:
>> Brian Clark wrote:
>>> Hello,
>>>
>>> I run Tomcat 6.0.x as a service on Windows 2003, using Sun JDK 1.6. I 
>>> was trying to use the jstack program, part of the JDK, to get a stack 
>>> dump from Tomcat/Java on my server. However, I ran into a problem. First 
>>> of all, Tomcat on Windows seems to "hide" the JVM instance. Java doesn't 
>>> show up in my process listing. I tried running jstack against the 
>>> Tomcat PID but it errored out.
>>> Any idea how to make jstack work with Tomcat running as a service on 
>>> Win2k3?
>>>
>> I can't answer your question, but a look here might provide a clue :
>> http://commons.apache.org/daemon/procrun.html
>>
>> That seems to be the way in which Tomcat is now implemented under 
>> Windows. Versions prior to 5.5 used to have a structure similar to the 
>> Unix version, with startup.bat and catalina.bat invoking Tomcat via Java, 
>> but that seems to have changed nowadays.
>>
>> Also, if it might help somewhat : open a command window and navigate to 
>> the Tomcat/bin directory. Then, instead of running tomcat as a service, 
>> just enter the "tomcatx.exe" command (where x is probably 6 in your case) 
>> (not the tomcatxW.exe). That will run Tomcat in the command window, maybe 
>> easier for you to figure out what is going on.
>> Not for me though.
>>
>
> Addendum :
> I just had another look at the Tomcat site. For version 5.5, there are 2 
> downloads for Windows : one is a zip, the other an msi installer.
> I must have in the past downloaded and installed the msi.
> I downloaded the zip version now, and that one seems to contain the usual 
> startup.bat and catalina.bat files, in addition to the Win32 tomcat5 and 
> tomcat5W executables.
> Maybe the .bat files allow to start Tomcat in the "traditional" way, via 
> Java etc.. ?

------------------------------------
As a Service the PID is TomcatX
>From the start.BAT its JAVA

The easiest way to get the PID is to type
netstat -noa
Its the one next to the port you on...

On windows... you install your service version EXE
Then you download the zip version and copy the missing BIN scripts across... 
then you have all the files

If you need thread dumps....

Start TC from the BAT file.....
When you need a dump... press ctrl + break from term window... easier than 
Jstack...

Andre is right..... as a service Tomcat appears under the non normal java... 
because its started from a windows service... not launched as a normal java 
process.

---------------------------------------------------------------------------
HARBOR : http://www.kewlstuff.co.za/index.htm
The most powerful application server on earth.
The only real POJO Application Server.
See it in Action : http://www.kewlstuff.co.za/cd_tut_swf/whatisejb1.htm
---------------------------------------------------------------------------










---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message