It could also be that the Permanent Generation has filled up, look up the docs 
on how to increase that or start with -XX:MaxPermSize=128M

-----Original Message-----
From: SANTOS, DANIEL (SBCSI) [mailto:[EMAIL PROTECTED]
Sent: 06 January 2005 14:57
To: Tomcat Users List; [EMAIL PROTECTED]
Subject: RE: Out of Memory when compiling JSP (Struts app on Tomcat
4.1.27)


Chachany,

It sounds like it's using the default of -Xmx64m.  Probably the best way
to troubleshoot out or memory errors is to see what is really happening
with garbage collecting, the same way that you tune it.  If you can add
these options, then the JVM will spit out all kinds of useful
information:

-XX:+PrintTenuringDistribution -XX:+PrintGCDetails -Xverbosegc

But it sounds like the problem is that it's not getting the options.
What you really need to figure out is exactly how the service is getting
started.  For instance, if it's calling tomcat.exe then I don't believe
that the JAVA_OPTS environment variable is ever looked at since that is
in the startup.sh and startup.bat files (I'm not 100% certain about that
however).

Find out how it's starting.  Also, post the version of Java you are
using (since the options I gave you above don't work on all versions, I
think 1.4 and up or 1.3 and up).  But the -Xverbosegc works all the way
back to 1.1 if I'm correct.

Daniel

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 06, 2005 8:25 AM
To: [email protected]
Subject: Out of Memory when compiling JSP (Struts app on Tomcat 4.1.27)


Hi all

I'm working on an application currently that is experiencing some
intermittent memory problems when installed onto our "integration
test" server, but not on the development staff's local laptops.

I have attempted to increase the maximum memory available to Tomcat by
creating a global environment variable (because tomcat runs as a
service)

JAVA_OPTS=-Xmx512M

Which doesnt seem to have made a difference. Is this the best way to
increaqte the memory available to an application? Is my syntax wrong?
Are there other options I can set that will help?

The weird thing is that when I look at the memory usage of Tomcat.exe,
the most memory it has used is 110,000

there seems to be no pattern to the memory errors (as usual) and it
happens a lot when compiling JSP files.

The system memory seems high, but not horribly so. I see the following
in Task Manager

MEM Usage = 885,000 (varies)

Commit Charge:
Limit : 2,522,244
Peak : 958,260

Anyone?

Thanks!

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

Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with it are 
confidential and solely for the use of the intended recipient. If you are not 
the intended recipient or the person responsible for delivering to the intended 
recipient, be advised that you have received this E-mail in error and that any 
use or copying is strictly prohibited. If you have received this E-mail in 
error please notify the beCogent postmaster at [EMAIL PROTECTED]
Unless expressly stated, opinions in this email are those of the individual 
sender and not beCogent Ltd. You must take full responsibility for virus 
checking this email and any attachments.
Please note that the content of this email or any of its attachments may 
contain data that falls within the scope of the Data Protection Acts and that 
you must ensure that any handling or processing of such data by you is fully 
compliant with the terms and provisions of the Data Protection Act 1984 and 
1998.


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

Reply via email to