Worrying problem

2003-11-20 Thread Walter do Valle
What's the problem with Tomcat in Linux? 
Sometimes it opens many threads and the command tomcat4 stop does nost stop all 
threads. 
I need to kill one by one. Why?

RE: Worrying problem

2003-11-20 Thread Shapira, Yoav

Howdy,

Sometimes it opens many threads and the command tomcat4 stop does
nost
stop all threads.
I need to kill one by one. Why?

When you say sometimes, what do you mean exactly?  Can you reproduce it
in a test case?  Is there a correlation between high load on your system
and a high number of threads?  There should be.  By how much does the
number of threads exceed your maxProcessors as configured in server.xml?

The tomcat shutdown script (I don't know what tomcat4 stop is) will shut
down the tomcat engine itself.  If your app or code used by your app
starts non-daemon threads, you are responsible for closing them
yourself.  Tomcat cannot do that for you.  These threads will prevent a
proper shutdown.  This has been discussed many times on this list in the
past.

Yoav Shapira



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Worrying problem

2003-11-20 Thread Walter do Valle


Sometimes it opens many threads and the command tomcat4 stop does nost
stop all threads.
I need to kill one by one. Why?

When you say sometimes, what do you mean exactly?  Can you reproduce it
in a test case?
2 -3 times by day. I don't know exactly what is causing the problem.
I can't reproduce that.

Is there a correlation between high load on your system
and a high number of threads?  There should be.
CPU was 70% free.

By how much does the
number of threads exceed your maxProcessors as configured in server.xml?
In server.xml maxProcessors=75 for but there is about 90 threads in the
system (ps -ef).

The tomcat shutdown script (I don't know what tomcat4 stop is) will shut
down the tomcat engine itself.
It's equivalent to catalina.sh stop. I never use shutdown.sh.

If your app or code used by your app
starts non-daemon threads, you are responsible for closing them
yourself.  Tomcat cannot do that for you.  These threads will prevent a
proper shutdown.  This has been discussed many times on this list in the
past.
I don't create any threads.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Worrying problem

2003-11-20 Thread Oscar Carrillo
You didn't state what Linux distribution or tomcat, or java version. Do
you use apache in front of tomcat?

Do you have the latest packages for your Linux distribution? In 
particular, nptl, gcc, kernel packages.

Have you tried the old threading model by setting it in your startup
script?:

LD_KERNEL_ASSUME=2.2.5

Oscar

On Thu, 20 Nov 2003, Walter do Valle wrote:

 
 
 Sometimes it opens many threads and the command tomcat4 stop does nost
 stop all threads.
 I need to kill one by one. Why?
 
 When you say sometimes, what do you mean exactly?  Can you reproduce it
 in a test case?
 2 -3 times by day. I don't know exactly what is causing the problem.
 I can't reproduce that.
 
 Is there a correlation between high load on your system
 and a high number of threads?  There should be.
 CPU was 70% free.
 
 By how much does the
 number of threads exceed your maxProcessors as configured in server.xml?
 In server.xml maxProcessors=75 for but there is about 90 threads in the
 system (ps -ef).
 
 The tomcat shutdown script (I don't know what tomcat4 stop is) will shut
 down the tomcat engine itself.
 It's equivalent to catalina.sh stop. I never use shutdown.sh.
 
 If your app or code used by your app
 starts non-daemon threads, you are responsible for closing them
 yourself.  Tomcat cannot do that for you.  These threads will prevent a
 proper shutdown.  This has been discussed many times on this list in the
 past.
 I don't create any threads.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Worrying problem

2003-11-20 Thread Shapira, Yoav

Howdy,

2 -3 times by day. I don't know exactly what is causing the problem.
I can't reproduce that.

You're going to have a tough time getting help solving a problem you
can't reproduce.

Is there a correlation between high load on your system
and a high number of threads?  There should be.
CPU was 70% free.

I didn't ask about the CPU load: I meant users hitting your webapp.  The
70% CPU free doesn't mean much, because your apps may not be CPU-bound.

By how much does the
number of threads exceed your maxProcessors as configured in
server.xml?
In server.xml maxProcessors=75 for but there is about 90 threads in
the
system (ps -ef).

This is why I was asking about the user load.  If there's a high load,
and tomcat created 75 request processing threads, 90 is not a surprising
number of total threads.  You always have a handful from the VM.  You
can see what threads are present using kill -s QUIT processId.

The tomcat shutdown script (I don't know what tomcat4 stop is) will
shut
down the tomcat engine itself.
It's equivalent to catalina.sh stop. I never use shutdown.sh.

Why not use shutdown.sh, since that just calls catalina.sh stop mostly,
if your script is truly equivalent?

I don't create any threads.

Can you say the same for the 3rd party code you use, if any?

Yoav Shapira



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]