You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Harish S Rathod <ha...@gmail.com> on 2008/11/14 19:53:12 UTC

Question regarding Tomcat memory

Hi,

To make our tomcat  heap size memory  to 8 GB we have set the below=20
settings echo $CATALINA_OPTS -Xms8192M -Xmx8192M -Xss1024K=20
-XX:PermSize=3D64m -XX:MaxPermSize=3D256m -Dfile.encoding=3DCp1252 Please=20
suggest is this ok ? as we are observing the maximum heap size memory for=20
tomcat gets a reduced bit to  around 7756736K and it keeps flucatating. Is=
=20
this the normal behaviour?.
The OS we are using is Linux 8.

Re: Question regarding Tomcat memory

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Chuck,

Caldarale, Charles R wrote:
> I don't know how log4j determines that value

AFAIK, Log4j doesn't have any memory-specific memory info logging. The
user has to do it themselves. I suspect they are simply using
System.getRuntime() and then printing values from there.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkkhgEQACgkQ9CaO5/Lv0PCIJACeMoYWMSQ+Za157tZlTkVoyUVn
yc0AniHr3pwj4u9wsYwdktJ5D5zO+r6G
=u+oy
-----END PGP SIGNATURE-----

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


RE: Question regarding Tomcat memory

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Harish S Rathod [mailto:harishjss2002@gmail.com]
> Subject: Re: Question regarding Tomcat memory
>
> -Xms8192M -Xmx8192M -Xss1024K -XX:PermSize=64m -XX:MaxPermSize=256m
> -Dfile.encoding=Cp1252

That's what I surmised.

> Please suggest is this ok ?

As long as you have the RAM to hold that much heap (plus the other memory required by the process), it should be o.k.  If you don't have at least 9 GB of RAM, you're going to be paging like mad, which will absolutely kill performance.

Again, setting -Xss is usually pointless.  I would set PermSize to the same value as MaxPermSize, just to avoid unnecessary expansion and contraction of the PermGen.

> - Well we are using 64 bit JDK

Which one?

> - We are prinitng the heap mem using Log 4J utitiy in the
> apllication logs.

I don't know how log4j determines that value; what is shown by JConsole or LambdaProbe?  (The latter can be found at www.lambdaprobe.org.)

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.

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


Re: Question regarding Tomcat memory

Posted by Harish S Rathod <ha...@gmail.com>.
Hi,
Sorry the content of the mail was bit messed up ,i have corrected the
settings wordings please read the below text

To make our tomcat  heap size memory  to 8 GB we have set the below
settings
-Xms8192M -Xmx8192M -Xss1024K -XX:PermSize=64m -XX:MaxPermSize=256m
-Dfile.encoding=Cp1252

Please suggest is this ok ? as we are observing the maximum heap size memory
for
tomcat gets a reduced bit to  around 7756736K and it keeps flucatating.Is
this normal behaviour
The OS we are using is Linux 8.
- Well we are using 64 bit JDK
- We are prinitng the heap mem using Log 4J utitiy in the apllication logs.





On Sat, Nov 15, 2008 at 4:01 AM, Caldarale, Charles R <
Chuck.Caldarale@unisys.com> wrote:

> > From: Harish S Rathod [mailto:harishjss2002@gmail.com]
> > Subject: Question regarding Tomcat memory
>
> First, use a different mailer or send only in plain text; whatever you're
> using is encoding even standard ASCII characters like "=".
>
> > To make our tomcat  heap size memory  to 8 GB we have set the below=20
>
> How much RAM and swap space do you have on the system?  What JVM are you
> using?  To go over 1.8 GB you need a 64-bit JVM.
>
> > $CATALINA_OPTS -Xms8192M -Xmx8192M -Xss1024K=20
>
> Setting -Xss is usually not useful, unless your application is very, very
> strange.
>
> > as we are observing the maximum heap size memory for
> > tomcat gets a reduced bit to around 7756736K and it
> > keeps flucatating.
>
> What are you using to do the "observing"?  When I run JConsole targeting a
> JVM with the exact settings you specify, it says this about the heap:
>
> Committed:  8,039,104 kbytes
>      Max:  8,039,104 kbytes
>
> This is on a SuSE 10 system, with JDK 1.6.0_07, in server mode.
>
>  - Chuck
>
>
> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
> MATERIAL and is thus for use only by the intended recipient. If you received
> this in error, please contact the sender and delete the e-mail and its
> attachments from all computers.
>
> ---------------------------------------------------------------------
> 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
>
>

RE: Question regarding Tomcat memory

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Harish S Rathod [mailto:harishjss2002@gmail.com]
> Subject: Question regarding Tomcat memory

First, use a different mailer or send only in plain text; whatever you're using is encoding even standard ASCII characters like "=".

> To make our tomcat  heap size memory  to 8 GB we have set the below=20

How much RAM and swap space do you have on the system?  What JVM are you using?  To go over 1.8 GB you need a 64-bit JVM.

> $CATALINA_OPTS -Xms8192M -Xmx8192M -Xss1024K=20

Setting -Xss is usually not useful, unless your application is very, very strange.

> as we are observing the maximum heap size memory for
> tomcat gets a reduced bit to around 7756736K and it
> keeps flucatating.

What are you using to do the "observing"?  When I run JConsole targeting a JVM with the exact settings you specify, it says this about the heap:

Committed:  8,039,104 kbytes
      Max:  8,039,104 kbytes

This is on a SuSE 10 system, with JDK 1.6.0_07, in server mode.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.

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