473,406 Members | 2,377 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Out Of Memory Exception

1
HELLO

I have developed some modules in java,executing them causes out of memory exception.
When i m trying to increase heap size in jdk 1.4 or jdk 1.5 i m getting following error.

Invalid flag:-Xmx

I tried setting both -Xmx & -Xms but same error.
pls let me know that following command line is correct.

javac -Xms256m -Xmx256m file.java
??????
Thx
Feb 9 '07 #1
2 2791
r035198x
13,262 8TB
HELLO

I have developed some modules in java,executing them causes out of memory exception.
When i m trying to increase heap size in jdk 1.4 or jdk 1.5 i m getting following error.

Invalid flag:-Xmx

I tried setting both -Xmx & -Xms but same error.
pls let me know that following command line is correct.

javac -Xms256m -Xmx256m file.java
??????
Thx
You set the heap size to the jvm when running not when compiling. Set the size fo the java command not javac command
Feb 9 '07 #2
rengaraj
168 100+
You set the heap size to the jvm when running not when compiling. Set the size fo the java command not javac command
You can visit :
you can increase the JVM heap size, see discussion

java -Xms<some_min_size> -Xmx<some_max_size>

-Xms<size> set initial Java heap size
-Xmx<size> set maximum Java heap size
-Xss<size> set java thread stack size

you need to set an initial heap size to the value that you want to support apart from the initial heap size.

Regards

but the problem may still occure

could you use a double buffer? be filling one buffer which another thread is writing the other buffer - you can then test to see if first buffer is full before the second is writen - if so you can think about solving that problem, e.g. may need faster machine, faster disk, bigger disk cache?

Visit:
http://www.thescripts.com/forum/thread585847.html
Feb 17 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: Ganesan selvaraj | last post by:
I using C# .net. i want to split the text files based of the some condition. my source text file size may be 4 kb to 4 gb. some time when i split the i got the "out of memory exception. when i...
6
by: Ganesan selvaraj | last post by:
I using C# .net. i want to split the text files based of the some condition. my source text file size may be 4 kb to 4 gb. some time when i split the i got the "out of memory exception. when i...
2
by: Ilkka | last post by:
I have created an C++ application with Windows Forms, ADO and SQL server 2005. Now I need to change something and started debugging the code. Then suddenly I receive an error. "An unhandled...
2
by: =?Utf-8?B?Tm9tYW4gQWxp?= | last post by:
Hi, We are facing a strange problem in our ASP. NET website. Some times it gives the following unhandled exception. Error Message: Exception of type System.Web.HttpUnhandledException was...
1
by: George2 | last post by:
Hello everyone, Such code segment is used to check whether function call or exception- handling mechanism runs out of memory first (written by Bjarne), void perverted() { try{
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.