Hello guys,

I have finally figured how to make JVM work the way I want it to. Setting
some of the following options helps control the allocated memory size by
huge amounts. I would strongly recommend using them. 

echo Setting JAVA_OPTS
set JAVA_OPTS=-Xmn32M -Xmx128M -XX:MaxHeapFreeRatio=30 -XX:+UseParallelGC
echo Using JAVA_OPTS: %JAVA_OPTS%

Related link would be : http://java.sun.com/docs/hotspot/VMOptions.html

Now the problem is these work on a Windows box when placed in catalina.bat
but fail on a redHat 9 (Kernel 2.4.20-8)machine, in two ways -
        1. When I place it in catalina.sh tomcat fails to start.
        3. When I place startup.sh, tomcat starts but the windows behavior
is not imitated.

Any suggestion,

Nandish Rudra
ECI Conference Call Services, LLC



-----Original Message-----
From: Nandish Rudra [mailto:[EMAIL PROTECTED]
Sent: Wednesday, August 11, 2004 11:09 AM
To: 'Tomcat Users List'
Subject: RE: FW: Memory Usage - Tomcat 5.0.25


Hello QM,

Thanks for your reply, it really cleared some things. First, tomcat has two
levels for memory - allocated vs. used. While allocated increases with every
spike by some amout and stays there, the used memor fluctuates. 

If I set the memory bounds for JVM by the mechanism you have said than once
the allocated reaches that level, tomcat will crash(out of memory
exception). Now, since all of the allcotaed memory is not being used, is
there a way to control the allocated memory, as in, make it fluctuate with
used memory.

Regards,
Nandish Rudra
ECI Conference Call Services, LLC



-----Original Message-----
From: QM [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 10, 2004 8:38 PM
To: Tomcat Users List
Subject: Re: FW: Memory Usage - Tomcat 5.0.25


On Tue, Aug 10, 2004 at 04:54:26PM -0400, Nandish Rudra wrote:
: I am writing about this error from yesterday. I used JProfiler to monitor
my
: memory usage. And am now sure that each and every static object is trashed
: when the application is undeployed and the profiler shows that memory is
: free and all instance of the objects are GC'd.

Something else to consider: the memory for the JVM process isn't just
the heap.  The process maintains some memory for itself, outside of the
designated heap ranges set with -Xmx and -Xms, for housekeeping and
such.  (This is often news to even experienced J2EE developers.)

That may very well be what you're seeing.

-QM

-- 

software  -- http://www.brandxdev.net
tech news -- http://www.RoarNetworX.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to