You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by John Econopouly <jo...@hotmail.com> on 2000/07/04 22:38:12 UTC

Scalability/concurrent users

I'm trying to get tomcat to work with alot of concurrent user connections.
So far, I can't seem to get it to work past about 250, and it seems very
slow - do any of you feel it can handle more?  I was hoping for 1000...

Details:
I'm running Redhat Linux 6.1, on a 500 MHz 686 w/ 1 gig of memory.
I'm using the Blackdown 1.2.2 JVM, and have tried up to -Xms512m -Xmx768m,
-green vs -native, jit/no jit.  I also tried the Sun JVM 1.2.2.  None of
this seems to have much affect - adding all that memory just sped it up
a bit, but once I went past 250 concurrent users, some users got dropped,
I got connection exceptions, etc.  I've been wondering if there is a hard
limit of 256 somewhere in the code...

Why I'm doing this:
I need to create a "push" system, where I send changes in price information
to a large number of clients (1,000+), all behind firewalls, in real-time
(a few seconds...).  So I was planning to have applets on the client side
that make HTTP get requests which are handled by a servlet that blocks in a
wait() state until there is information to return.  So all these connections
remain open, with (at least) one blocked thread each, until they all return.

Besides dropping alot of users beyond 250, the speed seems extremely slow.
It appears like it adds a second to the response time for every 30 extra
concurrent users.  I also tried using an apache front end, but that just
made performance even way slower, without improving capacity.
I've increased my maximum file descriptors into the thousands...
I've also seen some talk about maximum tasks - but don't know what they
are... can that be what's limiting me?

Any info at all greatly appreciated, I'm getting desperate...
thanks
j
________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


Re: Scalability/concurrent users

Posted by Shachor Gal <sh...@techunix.technion.ac.il>.

On Tue, 4 Jul 2000, Costin Manolache wrote:

> John Econopouly wrote:
> 
> > I'm trying to get tomcat to work with alot of concurrent user connections.
> > So far, I can't seem to get it to work past about 250, and it seems very
> > slow - do any of you feel it can handle more?  I was hoping for 1000...
> 
> :-)
> I am more than happy we can handle 250 in this release, but you'll have to wait
> for next one for 1000 !
> 

One question, what did you set your file limit for? Any socket will
require a file descriptor... for 1k sockets make sure that your limits are
"unlimited".

Also, look at your other limits, if you want to have K's of threads and 
sockets then you should make sure that you can do that, for example,  
AFIK, the old posix thread limit was 512 threads/process! Just make sure
that what you want is possible (for example, just try to open K threads
and see that things are OK).

One last thing, from experience, with K's of threads in the JVM the GC
synchronization overhead can be rather high on UNIX/NT (I heard that you
can open some 20-40K threads in a single JVM on AS/400 but never really
try that myself).

	Gal Shachor


Re: Scalability/concurrent users

Posted by Costin Manolache <co...@eng.sun.com>.
John Econopouly wrote:

> I'm trying to get tomcat to work with alot of concurrent user connections.
> So far, I can't seem to get it to work past about 250, and it seems very
> slow - do any of you feel it can handle more?  I was hoping for 1000...

:-)
I am more than happy we can handle 250 in this release, but you'll have to wait
for next one for 1000 !


> Details:
> I'm running Redhat Linux 6.1, on a 500 MHz 686 w/ 1 gig of memory.
> I'm using the Blackdown 1.2.2 JVM, and have tried up to -Xms512m -Xmx768m,
> -green vs -native, jit/no jit.  I also tried the Sun JVM 1.2.2.  None of
> this seems to have much affect - adding all that memory just sped it up
> a bit, but once I went past 250 concurrent users, some users got dropped,
> I got connection exceptions, etc.  I've been wondering if there is a hard
> limit of 256 somewhere in the code...

I don't think so, at least not in tomcat. >256 threads is a not easy - even for
unix.

You can of course use load balancing - and add a Unix process for each 100
concurent users ( 100 is a decent number, away from the limit ).

I never tried more than 120, all my performance tests are done with 40 clients,
which IMHO is a reasonable number for one instance.

> Any info at all greatly appreciated, I'm getting desperate...

Load balancing or a different  protocol - multicast may be a bit difficult, but
seems a good solution.

Costin


RE: Scalability/concurrent users

Posted by Matt Pease <ma...@fullscreen.com>.
you may try taking a look at www.volano.com  which compares many diff.
x86 JVMs ability to handle mucho threads.

Matt

> -----Original Message-----
> From: John Econopouly [mailto:johneco@hotmail.com]
> Sent: Tuesday, July 04, 2000 22:38
> To: tomcat-dev@jakarta.apache.org
> Subject: Scalability/concurrent users
>
>
>
> I'm trying to get tomcat to work with alot of concurrent user connections.
> So far, I can't seem to get it to work past about 250, and it seems very
> slow - do any of you feel it can handle more?  I was hoping for 1000...
>
> Details:
> I'm running Redhat Linux 6.1, on a 500 MHz 686 w/ 1 gig of memory.
> I'm using the Blackdown 1.2.2 JVM, and have tried up to -Xms512m -Xmx768m,
> -green vs -native, jit/no jit.  I also tried the Sun JVM 1.2.2.  None of
> this seems to have much affect - adding all that memory just sped it up
> a bit, but once I went past 250 concurrent users, some users got dropped,
> I got connection exceptions, etc.  I've been wondering if there is a hard
> limit of 256 somewhere in the code...
>
> Why I'm doing this:
> I need to create a "push" system, where I send changes in price
> information
> to a large number of clients (1,000+), all behind firewalls, in real-time
> (a few seconds...).  So I was planning to have applets on the client side
> that make HTTP get requests which are handled by a servlet that
> blocks in a
> wait() state until there is information to return.  So all these
> connections
> remain open, with (at least) one blocked thread each, until they
> all return.
>
> Besides dropping alot of users beyond 250, the speed seems extremely slow.
> It appears like it adds a second to the response time for every 30 extra
> concurrent users.  I also tried using an apache front end, but that just
> made performance even way slower, without improving capacity.
> I've increased my maximum file descriptors into the thousands...
> I've also seen some talk about maximum tasks - but don't know what they
> are... can that be what's limiting me?
>
> Any info at all greatly appreciated, I'm getting desperate...
> thanks
> j
> ________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
>
>


Re: Scalability/concurrent users

Posted by Vasile GABURICI <ga...@ss.pub.ro>.
On Tue, 4 Jul 2000, John Econopouly wrote:

> 
> I'm trying to get tomcat to work with alot of concurrent user connections.
> So far, I can't seem to get it to work past about 250, and it seems very
> slow - do any of you feel it can handle more?  I was hoping for 1000...
> 
> Details:
> I'm running Redhat Linux 6.1, on a 500 MHz 686 w/ 1 gig of memory.
> I'm using the Blackdown 1.2.2 JVM, and have tried up to -Xms512m -Xmx768m,
> -green vs -native, jit/no jit.  I also tried the Sun JVM 1.2.2.  None of
> this seems to have much affect - adding all that memory just sped it up
> a bit, but once I went past 250 concurrent users, some users got dropped,
> I got connection exceptions, etc.  I've been wondering if there is a hard
> limit of 256 somewhere in the code...

	Try IBM JDK 1.3.0 (alpha). AFAICT on socket business it is more
stable than Blackdown. You also get near 4-fold increase in performance.
Check: http://www.ss.pub.ro/~gaburici/nstomcat/perf/ for more on this.

	You are not saying what Tomcat version you are using, but for 3.1
beware that SimpleTcpConnector can be replaced with the faster PoolTcp*.

> Why I'm doing this:
> I need to create a "push" system, where I send changes in price information
> to a large number of clients (1,000+), all behind firewalls, in real-time
> (a few seconds...).  So I was planning to have applets on the client side
> that make HTTP get requests which are handled by a servlet that blocks in a
> wait() state until there is information to return.  So all these connections
> remain open, with (at least) one blocked thread each, until they all return.
> 
> Besides dropping alot of users beyond 250, the speed seems extremely slow.
> It appears like it adds a second to the response time for every 30 extra
> concurrent users.  I also tried using an apache front end, but that just
> made performance even way slower, without improving capacity.

	Use Apache 2 (alpha) or AOLserver 3.0 (production) with in-process
Tomcat (via JNI integration). I don't know if it will give any improvement
in capacity, but will give some in performance.

> I've increased my maximum file descriptors into the thousands...
> I've also seen some talk about maximum tasks - but don't know what they
> are... can that be what's limiting me?

	I don't remember what kernel RedHat 6.1 had (I skipped from 6.0 ->
6.2), but some older 2.2.x kernels had TCP/IP bugs that slowed them down.
 
> Any info at all greatly appreciated, I'm getting desperate...
> thanks
> j
> ________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
> 
>