Howdy,
As others said, java and tomcat are definitely multi-threaded ;)  We
have apps that run on 18-cpu machines, using all CPUs, handling hundreds
of concurrent requests without a problem.

It could be that your application is not CPU-bound, but perhaps
IO-bound?  Use a Profiler to determine where the CPU time is spent.  If
it in things like Socket#read or any of the java.io methods, you're
IO-bound.  That calls for a different refactoring than if you're
CPU-bound.

So you have -Xmx300m?  Why?  How did you determine that number?

Yoav Shapira
Millennium ChemInformatics


>-----Original Message-----
>From: Jens Ove Lillegraven [mailto:[EMAIL PROTECTED]
>Sent: Wednesday, November 12, 2003 10:17 AM
>To: [EMAIL PROTECTED]
>Subject: How to tune Tomcat and Java?
>
>Hi,
>
>We have a problem in that the Tomcat (java) process is the bottleneck
and
>is
>using only one CPU.
>There will be high load on the server when it is put online, so we are
>stress testing it offline now. Using the top command in Linux during
the
>stress test, it seems that java is the bottleneck of the system. But it
>uses
>not 100%, but about 45-50% of one CPU. We get no http error, the page
>performance (pages pr. second) is just getting worse as we put on more
>stress load. The max memory consumption is set to 300M, but I've never
seen
>java using more than 111M. I suppose the throughput would have
increased if
>both CPUs could be used, but is Java (Tomcat) a single processor
>application? The network throughput has a maximum average of 500kbps
>(kilo-bits) during the stress test, and should manage much more.
>Anyone who know how to make java and Tomcat performing better?
>
>Details of hardware and innstalled applications:
>Compaq ProLiant 6000, 2 x PII Xeon 400MHz, 1,3GB RAM
>Red Hat Linux Enterprise 3 ES
>J2EE: j2sdkee-1_3_1-linux
>J2SE: j2sdk-1_4_2_02-linux-i586
>Tomcat: 4.1.24
>MySQL: 4.0.16
>
>Tuning Tomcat memory (done):
>in /usr/bin/dtomcat4:
>  CATALINA_OPTS="-Xmx300M -Xms100M $CATALINA_OPTS $JPDA_OPTS"
>
>MySQL has been tuned, and is running very well.
>
>Thanks
>Jens Ove
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




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]

Reply via email to