You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Thomas Bezdicek <t....@lgsoft.at> on 2001/03/02 10:50:29 UTC
Just another Benchmark
Hi,
we tried the apachebench on our solaris system, to check out
differences between architectures and thereby we found a quite
interesting behaviour.
When serving a static page, apache uses the whole machine
resources while tomcat isn't (CPU usage 100% to 20%) and for
maybe this reason isn't serving at the same speed as apache.
Is there a limit somewhere in the java net or in tomcat?
We used apachebench with 'ab -c 10 -n 50000
Config:
apache with mod_jk, and ajp13 to tomcat.
Solaris 8
regards, tom
------- Apache 1.3.14 serving static page -------
This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
Server Software: Apache/1.3.14
Server Hostname: solaris.lgsoft.at
Server Port: 80
Document Path: /start.html
Document Length: 2669 bytes
Concurrency Level: 10
Time taken for tests: 98.686 seconds
Complete requests: 50000
Failed requests: 0
Total transferred: 146255850 bytes
HTML transferred: 133455338 bytes
Requests per second: 506.66
Transfer rate: 1482.03 kb/s received
Connnection Times (ms)
min avg max
Connect: 0 0 43
Processing: 1 19 1289
Total: 1 19 1332
------- Tomcat 3.2.1 serving static page -------
This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
Server Software: Apache/1.3.14
Server Hostname: solaris.lgsoft.at
Server Port: 80
Document Path: /pltest/start.html
Document Length: 2669 bytes
Concurrency Level: 10
Time taken for tests: 509.877 seconds
Complete requests: 50000
Failed requests: 0
Total transferred: 143600000 bytes
HTML transferred: 133450000 bytes
Requests per second: 98.06
Transfer rate: 281.64 kb/s received
Connnection Times (ms)
min avg max
Connect: 0 0 299
Processing: 94 101 128
Total: 94 101 427
RE: Just another Benchmark
Posted by Roy Wilson <de...@bellatlantic.net>.
Hi,
See below.
Roy
<snip>
> -----Original Message-----
> From: Thomas Bezdicek [mailto:t.bezdicek@lgsoft.at]
> Sent: 02 March 2001 09:50
> To: tomcat-dev@jakarta.apache.org
> Subject: Just another Benchmark
> Hi,
> we tried the apachebench on our solaris system, to check out
> differences between architectures and thereby we found a quite
> interesting behaviour.
> When serving a static page, apache uses the whole machine
> resources while tomcat isn't (CPU usage 100% to 20%) and for
> maybe this reason isn't serving at the same speed as apache.
> Is there a limit somewhere in the java net or in tomcat?
Just curious: you say "CPU usage 100%". I guess what I'm asking is
whether you assume that Apache keeps the CPU busy 100% of the time based
on the ratio of the throughputs (requests per second) or whether you
measured CPU busy using sar (or something like it). FWIW, in measurements
of Apache I've done, I've rarely seen CPU utilization above about 75%.
Roy
RE: Just another Benchmark
Posted by Ron Pitts <ro...@claripoint.com>.
apache will also be faster for serving static pages, thats what apache is
good at. Tomcat CPU will depend on the task its doing and whats spare CPU is
avaliable. I dont think there is a limit in java or tomcat
-----Original Message-----
From: Thomas Bezdicek [mailto:t.bezdicek@lgsoft.at]
Sent: 02 March 2001 09:50
To: tomcat-dev@jakarta.apache.org
Subject: Just another Benchmark
Hi,
we tried the apachebench on our solaris system, to check out
differences between architectures and thereby we found a quite
interesting behaviour.
When serving a static page, apache uses the whole machine
resources while tomcat isn't (CPU usage 100% to 20%) and for
maybe this reason isn't serving at the same speed as apache.
Is there a limit somewhere in the java net or in tomcat?
We used apachebench with 'ab -c 10 -n 50000
Config:
apache with mod_jk, and ajp13 to tomcat.
Solaris 8
regards, tom
------- Apache 1.3.14 serving static page -------
This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
Server Software: Apache/1.3.14
Server Hostname: solaris.lgsoft.at
Server Port: 80
Document Path: /start.html
Document Length: 2669 bytes
Concurrency Level: 10
Time taken for tests: 98.686 seconds
Complete requests: 50000
Failed requests: 0
Total transferred: 146255850 bytes
HTML transferred: 133455338 bytes
Requests per second: 506.66
Transfer rate: 1482.03 kb/s received
Connnection Times (ms)
min avg max
Connect: 0 0 43
Processing: 1 19 1289
Total: 1 19 1332
------- Tomcat 3.2.1 serving static page -------
This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
Server Software: Apache/1.3.14
Server Hostname: solaris.lgsoft.at
Server Port: 80
Document Path: /pltest/start.html
Document Length: 2669 bytes
Concurrency Level: 10
Time taken for tests: 509.877 seconds
Complete requests: 50000
Failed requests: 0
Total transferred: 143600000 bytes
HTML transferred: 133450000 bytes
Requests per second: 98.06
Transfer rate: 281.64 kb/s received
Connnection Times (ms)
min avg max
Connect: 0 0 299
Processing: 94 101 128
Total: 94 101 427
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, email: tomcat-dev-help@jakarta.apache.org
Re: Just another Benchmark
Posted by cm...@yahoo.com.
> what platform/os? i believe your previous claims have been on NT, is this
> also for unix now as well?
I've never tried on NT - and it would be pretty difficult anyway
( to get NT on my computer :-)
I'm using Linux/JDK1.3.
Again, I'm talking about overhead - i.e. the time spent in
tomcat ( if the servlet is doing anything - well, that's servlet
performance, not something related with the container).
Costin
Re: Just another Benchmark
Posted by Jon Stevens <jo...@latchkey.com>.
on 3/3/01 6:55 AM, "cmanolache@yahoo.com" <cm...@yahoo.com> wrote:
>> on 3/2/01 11:58 PM, "cmanolache@yahoo.com" <cm...@yahoo.com> wrote:
>>
>>> For "real" production servers I hope you'll use Apache, and for embeding
>>> tomcat in apps or development you don't need 500 requests per seconde.
>>
>> What if we need 500 requests per second for non-static files? :-)
>
> You got them already - tomcat overhead for serving servlets is comparable
> with apache overhead for serving static pages.
>
> Everything else is up to the servlet implementation.
>
> ( actually, tomcat overhead is smaller than Apache 1.3, but
> Apache 2.0 is faster )
>
> Costin
what platform/os? i believe your previous claims have been on NT, is this
also for unix now as well?
-jon
--
If you come from a Perl or PHP background, JSP is a way to take
your pain to new levels. --Anonymous
<http://jakarta.apache.org/velocity/> && <http://java.apache.org/turbine/>
Re: Just another Benchmark
Posted by cm...@yahoo.com.
> on 3/2/01 11:58 PM, "cmanolache@yahoo.com" <cm...@yahoo.com> wrote:
>
> > For "real" production servers I hope you'll use Apache, and for embeding
> > tomcat in apps or development you don't need 500 requests per seconde.
>
> What if we need 500 requests per second for non-static files? :-)
You got them already - tomcat overhead for serving servlets is comparable
with apache overhead for serving static pages.
Everything else is up to the servlet implementation.
( actually, tomcat overhead is smaller than Apache 1.3, but
Apache 2.0 is faster )
Costin
Re: Just another Benchmark
Posted by Jon Stevens <jo...@latchkey.com>.
on 3/2/01 11:58 PM, "cmanolache@yahoo.com" <cm...@yahoo.com> wrote:
> For "real" production servers I hope you'll use Apache, and for embeding
> tomcat in apps or development you don't need 500 requests per seconde.
What if we need 500 requests per second for non-static files? :-)
-jon
Re: Just another Benchmark
Posted by cm...@yahoo.com.
Well, there is a possible explanation :-)
The static interceptor ( which serves static files ) was never tuned or
optimized. It probably does multiple accesses to disk, while in
Apache there are a number of low-level optimizations, caching, etc.
I am not very interested in spending time tuning the StaticInterceptor - I
would rather spend the same time making sure setting up Tomcat + Apache is
as easy as possible, and just let Apache do what it's designed to (
serve static files ) and tomcat do it's job ( servlets + jsp ) :-)
For "real" production servers I hope you'll use Apache, and for embeding
tomcat in apps or development you don't need 500 requests per seconde.
Feel welcome to contribute any code that would improve the performance,
or use apache for static files :-)
Costin
> Hi,
>
> we tried the apachebench on our solaris system, to check out
> differences between architectures and thereby we found a quite
> interesting behaviour.
>
> When serving a static page, apache uses the whole machine
> resources while tomcat isn't (CPU usage 100% to 20%) and for
> maybe this reason isn't serving at the same speed as apache.
> Is there a limit somewhere in the java net or in tomcat?
>
> We used apachebench with 'ab -c 10 -n 50000
> Config:
> apache with mod_jk, and ajp13 to tomcat.
> Solaris 8
>
> regards, tom
> ------- Apache 1.3.14 serving static page -------
> This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
> Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
> Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
>
> Server Software: Apache/1.3.14
> Server Hostname: solaris.lgsoft.at
> Server Port: 80
>
> Document Path: /start.html
> Document Length: 2669 bytes
>
> Concurrency Level: 10
> Time taken for tests: 98.686 seconds
> Complete requests: 50000
> Failed requests: 0
> Total transferred: 146255850 bytes
> HTML transferred: 133455338 bytes
> Requests per second: 506.66
> Transfer rate: 1482.03 kb/s received
>
> Connnection Times (ms)
> min avg max
> Connect: 0 0 43
> Processing: 1 19 1289
> Total: 1 19 1332
>
> ------- Tomcat 3.2.1 serving static page -------
> This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
> Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
> Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
>
> Server Software: Apache/1.3.14
> Server Hostname: solaris.lgsoft.at
> Server Port: 80
>
> Document Path: /pltest/start.html
> Document Length: 2669 bytes
>
> Concurrency Level: 10
> Time taken for tests: 509.877 seconds
> Complete requests: 50000
> Failed requests: 0
> Total transferred: 143600000 bytes
> HTML transferred: 133450000 bytes
> Requests per second: 98.06
> Transfer rate: 281.64 kb/s received
>
> Connnection Times (ms)
> min avg max
> Connect: 0 0 299
> Processing: 94 101 128
> Total: 94 101 427
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, email: tomcat-dev-help@jakarta.apache.org
>