tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alan Chaney <a...@compulsivecreative.com>
Subject Re: Tomcat problem on a multiple CPU system
Date Sun, 04 May 2008 21:32:34 GMT
Hi Antoine

The thing to remember is that this is a system which has (at least) four 
main parts:

1. Tomcat
2. The operating system
3. A network connection
4. Your application

(and potentially)

5. A database (but you didn't mention that)

Here are some questions.

1. How do you make the connection to the servlet. Does the browser run 
on the same machine as the application?

2. Does you application create network traffic? If so, how many bytes 
are transferred to the browser? Each servlet thread will have to wait 
until the application has transferred all the data out.

3. What kind of disk activity does your application generate? Is it 
different when the app is running from the servlet?

Probably somewhere your servlet threads are sleeping waiting for a 
resource. You could do a thread dump to see what is happening (I don't 
use Windows so I can't remember how you do that with the Win setup)

In the end, you'll need to profile the system to work out where the 
bottlenecks are. You'll need to use network analysers and probably Java 
profilers to track down what's happening such as when packets are 
received, when the replies are generated and maybe profile what your 
app. is doing.

HTH

Alan Chaney




Gilbert, Antoine wrote:
> Hi
> 
>  
> 
> I have a 2x quad core (8 cpu units) server.
> 
>  
> 
> If I start a java program and this one is launching (at the same time) 8
> thread doing some CPU intensive jobs, all the CPU are used at 100%, and
> that's what I'm expecting..
> 
>  
> 
> But, if I am using tomcat, and I call a servlet 8 times to process these
> 8 jobs, it take longer to execute these same 8 jobs and all the CPU are
> not used at 100%, it's more like 30%...
> 
>  
> 
> Any idea about this problem or behavior ? I'm using Tomcat 5.5.17,
> windows, JDK 1.6
> 
>  
> 
> Antoine
> 
> 
> 
> !DSPAM:481e1bf27941527717022!
> 

---------------------------------------------------------------------
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