Win a copy of Rust Web Development this week in the Other Languages forum!

sateesh narahari

Greenhorn
+ Follow
since Jan 11, 2010
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by sateesh narahari

M Burke wrote:Tomcat 6.0.16 running on JVM 1.6 Windows 2003 occasionally uses 100% of CPU(sometimes during off peak hours) .Is there any way to find out which thread is consuming the most CPU ? How can we do a thread dump if needed.Though I have specified a timeout in my config file, I see some request threads(like for a image) with enormous processing times.Could this be the culprit.How can we go about resolving this issue.

These are the configurations in server.xml

<Connector port="8080" protocol="HTTP/1.1" redirectPort="8443" address="localhost"

enableLookups="false" disableUploadTimeout="true"

maxThreads="200" acceptCount="100" connectionTimeout="120000" maxHttpHeaderSize="4096" />

<Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"

maxThreads="150" scheme="https" secure="true"

clientAuth="false" sslProtocol="TLS" />

<Connector port="8009" protocol="AJP/1.3" redirectPort="8443"

enableLookups="false" disableUploadTimeout="true"

>



You can download Tcat Server ( Disclaimer: I work on the product), which shows you the CPU and memory utilization and also shows you the current status of all threads running in Tomcat. That would be another way to look at threads ( in addition to what Tim and others suggested ).

Best Regards,
Sateesh

12 years ago

Samanthi perera wrote:anyway what is the use of CATALINA_HOME ?
Why we set this variable?



CATALINA_HOME is used by Tomcat startup scripts and Tomcat itself. Tomcat converts it from an environment variable to a system property, which gets used in the Tomcat code. If you do not set CATALINA_HOME and start Tomcat using the startup scripts, it tries to set CATALINA_HOME.

For more help on getting started with Tomcat, you can checkout our Tomcat resource page here: http://www.mulesoft.com/understanding-apache-tomcat

Hope this helps.

Best Regards,
Sateesh Narahari
MuleSoft
12 years ago

trupti nigam wrote:Hi
I start my tomcat as "catalina jpda start" from the tomcat bin directory.
I need to pass -Denvironment.name=-dev5 variable in tomcat startup script.
How do I pass it?
What changes I need to make to my startup script?
I tried to setting my environment varibale as environment.name=-dev5 but it's not working. How Do I pass this option in tomcat startup script.

thanks
Trupti



You can set JAVA_OPTS or CATALINA_OPTS and catalina.sh ( or .bat ) should pick it up. If you want a visual way to do this, you can download for free Tcat Server from MuleSoft ( Disclaimer: I work for them)
12 years ago