I'm using dbforms2.4 with MSSQL database and tomcat 4.1.2.
My table tbl_Client contains about 42000 records. I use a select box to show all of these clients. I don't have any problem when only 1 user access data. But more than 1 user then tomcat throw the exception OutOutMemoryError.
So I try again with bookstore example. In bookstore.script, I insert into table book about 5000 records. After that, I run the testHowtoChangeSelectBox.jsp page and receive the same error.
I don't know why we have that error? tomcat overloaded or any reason? How to fix it?
Best regards,
Meg.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks for your helps. I adjusted the environment variable JAVA_OPTS to add more memory and I don't receive that error any more. (but I still worried)
cheers,
Meg.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I also get the same error message:"java.lang.OutOfMemoryError"
I am using dbfroms2.4, tomcat5.0
In my code, I ask user for password and then do "searchFieldNames", where in db I have only 2 records.
Any idea what is why it is JVM is out of memory?
Did you fix yours? How?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Seems that this is a different problem. The here discussed problem is a special problem with huge datasets and mysql.
Your problem seems to be different. Could try to debug?
Henner
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Anonymous
-
2004-12-08
Hi
java.lang.OutOfMemoryError means that your JVM is running out of heap space, and
is such not a dbforms related error, but a java in general error.
I believe the java maximum heap size by default equals 64MB, you can increase this value by adding -Xmx<value>M on the command line, for example -Xmx128M
gives your JVM a maximum heap size of 128MB of memory.
The solution is to configure Tomcat to use a larger heap size. This can be done by editing [TOMCAT_DIR]/bin/catalina.bat (MS Windows) or catalina.sh (Unix systems). You can increase the heap size by adding a parameter to the environment variable JAVA_OPTS. The parameter to be added is '-Xmx128M' (where the number 128 indicates that 128 Megabytes should be used. Increase as required).
For catalina.bat there now should be a line in your file that looks like this:
set JAVA_OPTS=-Xmx128M
For catalina.sh the line should look like this:
JAVA_OPTS='-Xmx128M'
You know, I configured tomcat with:
1) Initital memory pool = 64MB
2) Maximum memory pool = 512MB
3) Thread stack size = 128KB
To solve the OutOfMemory problem, I guess that we don't only increase Java heap stack, but also we need to release the memory for recordset which is controlled by DbForms, or something like that. I don't know what it is exactly, I just guess ... I tried to find out a problem but I haven't find yet.
Actually, may you explain to me the Dbforms architecture, i mean the inside of Dbforms, the way that it controls the data for navigation (for example) and how to release the memory. Thank you so much.
Best regards,
Meg.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm using dbforms2.4 with MSSQL database and tomcat 4.1.2.
My table tbl_Client contains about 42000 records. I use a select box to show all of these clients. I don't have any problem when only 1 user access data. But more than 1 user then tomcat throw the exception OutOutMemoryError.
So I try again with bookstore example. In bookstore.script, I insert into table book about 5000 records. After that, I run the testHowtoChangeSelectBox.jsp page and receive the same error.
I don't know why we have that error? tomcat overloaded or any reason? How to fix it?
Best regards,
Meg.
I upgraded tomcat to version 5.5.0 and run bookstore example again, but I still receive the OutOutMemory error. This is my error:
"root cause
java.lang.OutOfMemoryError: Java heap space
"
I think that 5000 records are not too much. I have no idea what's a problem? May you help me?
Thanks,
Meg.
Where do you get this exeception? During the query?
Which sql driver and database do you use?
If it's mysql then this could help:
http://sourceforge.net/tracker/index.php?func=detail&aid=1000060&group_id=17608&atid=217608
cheers,
Henner
Thanks for your helps. I adjusted the environment variable JAVA_OPTS to add more memory and I don't receive that error any more. (but I still worried)
cheers,
Meg.
I also get the same error message:"java.lang.OutOfMemoryError"
I am using dbfroms2.4, tomcat5.0
In my code, I ask user for password and then do "searchFieldNames", where in db I have only 2 records.
Any idea what is why it is JVM is out of memory?
Did you fix yours? How?
Seems that this is a different problem. The here discussed problem is a special problem with huge datasets and mysql.
Your problem seems to be different. Could try to debug?
Henner
Hi
java.lang.OutOfMemoryError means that your JVM is running out of heap space, and
is such not a dbforms related error, but a java in general error.
I believe the java maximum heap size by default equals 64MB, you can increase this value by adding -Xmx<value>M on the command line, for example -Xmx128M
gives your JVM a maximum heap size of 128MB of memory.
The solution is to configure Tomcat to use a larger heap size. This can be done by editing [TOMCAT_DIR]/bin/catalina.bat (MS Windows) or catalina.sh (Unix systems). You can increase the heap size by adding a parameter to the environment variable JAVA_OPTS. The parameter to be added is '-Xmx128M' (where the number 128 indicates that 128 Megabytes should be used. Increase as required).
For catalina.bat there now should be a line in your file that looks like this:
set JAVA_OPTS=-Xmx128M
For catalina.sh the line should look like this:
JAVA_OPTS='-Xmx128M'
Reference: http://jakarta.apache.org/tomcat/faq/memory.html
best regards
Audun
Hi,
Frankly, I did use the solution that increases the Java heap stack with '-Xmx512M', but I've still got the OutOfMemory problem.
This problem occurs exactly when many users run the application concurrently. Do you have any idea to solve the root of this problem?
Best reagrds,
Meg.
Do you use the bookstore example with mysql or with hsql?
Henner
Hi Henner,
You know, I configured tomcat with:
1) Initital memory pool = 64MB
2) Maximum memory pool = 512MB
3) Thread stack size = 128KB
To solve the OutOfMemory problem, I guess that we don't only increase Java heap stack, but also we need to release the memory for recordset which is controlled by DbForms, or something like that. I don't know what it is exactly, I just guess ... I tried to find out a problem but I haven't find yet.
Actually, may you explain to me the Dbforms architecture, i mean the inside of Dbforms, the way that it controls the data for navigation (for example) and how to release the memory. Thank you so much.
Best regards,
Meg.
Please could you build an example case based on bookstore? With some code to fill the database? And an test page?
That would help!
Henner