You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Tomcat Random <to...@gmail.com> on 2013/07/19 19:37:45 UTC
Multiple instances of Tomcat 7.0 on one server
We currently are setting a site that receives fairly heavy traffic (5000
simultaneous users). We have two physical servers.
As a general idea, is there performance to be gained by running multiple
instances of Tomcat 7.0? For example, two instances on one physical server
and two instances on the other physical server? Assume all are running the
same webapp.
TIA
Re: Multiple instances of Tomcat 7.0 on one server
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Leon,
On 7/19/13 3:48 PM, Leon Rosenberg wrote:
> * you have multiple physical resources your app can't use properly.
> For example if you could give each instance its own database or its
> own file system.
Related: if you are running on a 32-bit OS, you can't use huge heaps.
You can load-balance between several JVM instances on the same
physical machine and effectively use more heap space (across the
cluster, not in a single JVM, of course).
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQIcBAEBCAAGBQJR7XWnAAoJEBzwKT+lPKRYaVMQAMpUfnxEHG+CsG7fA6qAVEAj
q7Nfc/zVy4wJS0vYJ3KIgzHVL0fh1chPdjEfCr193eNXifyYb+KK4QCN5XsbZGm4
MIqK9i5iws5r9lHMr91ZnYdPVi+1E70RLLe5a05K9nZIBinS9yqmsLCqvR0WVHS+
7VlROJCJK62O/fabP3CQsODSmtr1egG/CQudYfm9BcITwYuuuAplzrY+j3J1RxcP
sYGw0TVE6HmS2O7tDZAbt1v3egmA/vTh2At6q73/qREWYOLt3u3R4w0g7j4jlvdi
7J8R/WjdHGRdVzdTZhhwAeSW1O3YYr1EiWrrRIcQ0c7l6KeVfG0R4YhDa46s8ldK
87cycV3v4IHwt+7qwWvKdwoMupX27dQQDX0NraLnvIMlIRfDpKOjDNm+GDCrkrfv
a3nFmaK+jxit3enOd4qcfL5muqI9EgB0rMmL66+lPnzaH54NAlUN5AKPLCs+/dDj
q+3D6E8+phWdp3pwdqO3StgUwgqvnLhXP1F/VjBxzBaJvJFSobcDvHaDm0A1PzQw
m34r72uszhUfiOvyjyJyar+LJNiNWhmQfbhSm1o5wqsHhWcp1A8rPMGZblRrut/n
+FCMBESzLAbRjFSCqBAy5FSO9U1HwlehWUSfyL9fNh0asFLll6FHkzBc32qrw1+Z
ztyc45cuzp2lP86/ljvg
=vuwi
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Multiple instances of Tomcat 7.0 on one server
Posted by Leon Rosenberg <ro...@gmail.com>.
Hello Mr. Random,
as usual there is no easy answer here.
I think the most correct answer would be RATHER NOT.
There is rather no performance to be gained but running multiple instances
of the same app in multiple tomcats on the same physical machine except for:
* you need a lot of heap per session. In this case you will probably be
able to save gc time and performance. So in case you need more than 12 Gb
Heap separation would make sense.
* you have multiple physical resources your app can't use properly. For
example if you could give each instance its own database or its own file
system.
* you have concurrency issues in your application.
Drawbacks:
- Database. If you have one. You will have more connections and evtl. more
locks. And both are limited resources.
If you want a more detailed answer, you should tell us a bit about your
app.
Or, better, you start to monitor your app, run one physical server with one
instance and another one with two and compare.
By using a monitoring tool like moskito: http://www.moskito.org.
regards
Leon
On Fri, Jul 19, 2013 at 7:37 PM, Tomcat Random <to...@gmail.com>wrote:
> We currently are setting a site that receives fairly heavy traffic (5000
> simultaneous users). We have two physical servers.
>
> As a general idea, is there performance to be gained by running multiple
> instances of Tomcat 7.0? For example, two instances on one physical server
> and two instances on the other physical server? Assume all are running the
> same webapp.
>
> TIA
>
Re: Multiple instances of Tomcat 7.0 on one server
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
To whom it mat concern,
On 7/19/13 1:37 PM, Tomcat Random wrote:
> We currently are setting a site that receives fairly heavy traffic
> (5000 simultaneous users). We have two physical servers.
>
> As a general idea, is there performance to be gained by running
> multiple instances of Tomcat 7.0? For example, two instances on one
> physical server and two instances on the other physical server?
> Assume all are running the same webapp.
You are unlikely to see a performance benefit by running two (or more)
Tomcat instances on the same server.
There are other benefits, though. For instance, you can configure
Tomcat for load-balancing and then use a fronting server like httpd to
direct traffic to a subset of your instances in order to, for
instance, upgrade each instance individually with no (perceived)
downtime. You can of course do this with separate physical servers, too.
Separate Tomcat instances means that you can run separate Tomcat
versions and separate JVM versions in parallel. We find this very
valuable at $WORK and so we run each webapp in a separate JVM even
when multiple webapps are deployed on a single physical server.
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQIcBAEBCAAGBQJR7XVKAAoJEBzwKT+lPKRYaWgP/2ClDW8TF8bOCQPgisyDZ+JB
tufmVcz5TZnmenvT2Tk9W8Qf9a/f37Ttv3u4h4OPmoUZLc4XmsPsLjQcRSNN3p76
xd401Ngj7WhuVxL+KescDxO0HApG/TDTNbcGeMgLXpYorAaqlVQZW3ADoQ0+vJGY
KujBdlGYqmgoQETtd2ewqzn5OsLWiuNsgwnm9CiI1P658Ljaik/0Upr18rhP4uno
eSkAH/y6Ojxd0pqQIoyrKPoW7xbcX476VIBc7VabSSQwV2MmEBm02SaJ4eq+Ms0/
nCosx8nt6DDwzeWEI4dzC3eGpJZ9bZoclpfjQyLEvHkODkTmds54YRvuzzlwlKus
59s3lckIL+WOmPTrCv5Jam6ReyuB/aCWlRNVOEBiiBiB40SN+yNwm878m4ALWmfK
sr0zwMofJjFc/j3q3XCZzknvnga5MdBVaNYddOyWYcwILCK4ODrA6SxIkJ0X2Pah
0/MMQvkNYVN1HYm7z9IAKlN/SMoLiz+hmruCv/xnYpZKO0dxiX34fP++nnJFdpa3
gfu1U+7HJFWeY3xtBePDuoyVYhxK4tP3WKbG+gRr3d56k7mb8XkHqSguhvl5VlvN
Y4h+VW1UOfem7swv8Y63ey9AykZamY/t+9dI9N88+hTDQCO4+UB/uEQn5ks5qsx6
qJvHUTt6zYIVhus6DiWj
=F6ZA
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org