Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tomcat settings 1

Status
Not open for further replies.

colinholt

Technical User
Sep 27, 2004
7
GB
Hi
We run Tomcat on a 2.5ghz and 2gb of RAM.
It hosts Documentum, with 800 users and around 70-80 concurrently accessing Documentum, either running Queries, checking out or checking in Documents.

We have weaked the server XML to cater for these number of users.

Periodically once or twice a month we get java.outofmemory error. The only solution is to bounce the main server, and then reinitialise Tomcat.

Changes Made, to address timeout and Connection timing.

Changes
<!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
<Connector className="org.apache.catalina.connector.http.HttpConnector"
port="8080" minProcessors="5" maxProcessors="75"
enableLookups="true" redirectPort="8443"
acceptCount="10" debug="0" connectionTimeout="60000"/>
<!-- Note : To disable connection timeouts, set connectionTimeout value
to -1 -->

MaxProcessors="1000"
AcceptCount="100"
ConnectionTimeout="-1" /
Minprocessors=10
Compression=on
Buffersize=4096

Is there anything else I need to look at adjusting to overcome this out of memory error.

W2000 SP4 Java 1.4.1

regards

colin


 
How much memory is Tomcat starting with (ie how much memory have you got assigned to the JVM) ?

Even if you had 16 million terabytes of RAM, if the JVM is still only starting with the default 16 Mb, it would not use any more RAM than that ...

--------------------------------------------------
Free Database Connection Pooling Software
 
memeory is 4GB but we have not reassigned the memory values for JVM
 
In that case, your 4Gb of RAM is not actually being used.

Depending on what tomcat version you are using, and whether you are using the windows service version, you should alter the JVM arguments that hosts Tomcat to allocate more memory.

--------------------------------------------------
Free Database Connection Pooling Software
 
Thanx Sedj
Next silly question.

Apache 4.0.6 is there version
JAVA c:\jdk1.3.1_12

Apache is run as a service and is stopped and started through Services Applet in Win2kPro SP4.

To assign via catalina.bat
AFTER
execjava=%_runjava%
Add line
Set_Execjava=%execjava% -xms128 - xms512m is that line correct and with 4gb what would optimum values be.
is there also a variable for setting HEAP Size.

How is the JVM initialised if Apache is restarted as a SERVICE.

Finally can these variables be set through enviromental variables??

 
To assign via catalina.bat
AFTER
execjava=%_runjava%
Add line
Set_Execjava=%execjava% -xms128 - xms512m is that line correct and with 4gb what would optimum values be.
is there also a variable for setting HEAP Size.

Yes, that is the line ... I would assign :

-Xms2048 -Xmx2048

which will give you tons of mem, plus a load for the OS ...

How is the JVM initialised if Apache is restarted as a SERVICE.
Not sure ... we run linux & UNIX ... but I would hope that there was some setting in the service gui thing that allowed you to control the heap sizes explicitly, OR, allows you to pass arguments to the JVM - if there is, then add in your Xms/Xmx values.

Finally can these variables be set through enviromental variables??
I don't think so ...




--------------------------------------------------
Free Database Connection Pooling Software
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top