This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 104033 - OutOfMemory error encountered in IDE
Summary: OutOfMemory error encountered in IDE
Status: CLOSED INVALID
Alias: None
Product: ide
Classification: Unclassified
Component: Performance (show other bugs)
Version: 3.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: issues@performance
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2007-05-16 01:10 UTC by frankioski
Modified: 2011-05-25 11:37 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
messages.log (101.49 KB, text/plain)
2007-05-16 04:29 UTC, frankioski
Details
messages.log (2.01 MB, text/plain)
2008-08-25 06:20 UTC, nleck
Details
our work around for similar issue in our code. (3.03 KB, text/html)
2008-08-25 23:39 UTC, nleck
Details

Note You need to log in before you can comment on or make changes to this bug.
Description frankioski 2007-05-16 01:10:52 UTC
OutOfMemory error encountered in IDE while performing various tasks:
1. Checking out from VCS
2. Ant build
Comment 1 frankioski 2007-05-16 04:29:15 UTC
Created attachment 42443 [details]
messages.log
Comment 2 Marian Mirilovic 2007-05-22 13:03:59 UTC
Hi frankioski,
we need more informations for evaluation of this issue :
What type of project have you been working on (was opened) ? 
Have you changed Xmx (in etc/netbeans.conf or on command line) value ?
How much memory do you have ?

Comment 3 frankioski 2007-05-24 22:16:04 UTC
Project type: Web Project with Existing Ant Script.  It consists of code lines
from three CVS/SVN modules.

Xmx value: -J-Xms32m -J-Xmx128m

RAM: 1 GB
Comment 4 nleck 2008-08-25 06:18:01 UTC
Here is message log from an IDE that was running a program but was not being used otherwise. 
Comment 5 nleck 2008-08-25 06:20:25 UTC
Created attachment 68218 [details]
messages.log
Comment 6 Tomas Pavek 2008-08-25 17:33:26 UTC
There's many "java.io.IOException: Not enough space" exceptions. Is it possible that the drive where your user dir is 
runs out of space?

As for the out of memory error, from the log I can see -Xmx3072m which is pretty huge heap (32GB system). It is really 
strange it can go out of memory.

Can you create a histogram via jmap and attach it here? So we get some idea what is occupying all the memory.
jmap -histo <pid>
Comment 7 nleck 2008-08-25 23:37:37 UTC
We hit this issue in our code also. If you set -Xmx3600m on a 32bit Java program you can get an error when calling
setCollectionUsageThreshold(requiredThreadhold) as the underlying C programs use the max Integer size ie. 2gigs to check
the parameter and throws an exception. This I believe is wrong ( haven't filed a bug for the JDK) please see the
attached work around from our code. 

The work around in this case was to set the max memory of the IDE lower ie. -Xmx2048m

So.... if you get an OutOfMemory, reduce the size of the memory ;-)  
Comment 8 nleck 2008-08-25 23:39:05 UTC
Created attachment 68286 [details]
our work around for similar issue in our code.
Comment 9 nleck 2008-08-25 23:56:22 UTC
sorry... lowering the memory DOESN'T fix the issue.
Comment 10 Tomas Pavek 2008-08-26 13:56:19 UTC
I'm not sure if the max heap size is a problem here or not. You can definitely set it lower, I don't think it makes 
much sense to give it more than 1GB.

Anyway, with the adjusted setting, are you running into the OutOfMemoryError again? If yes, can you create the 
histogram? Thanks.
Comment 11 Marian Mirilovic 2009-09-18 14:11:29 UTC
Without requested information for long time - INVALID. We can't do anything in this case. Reporter, please add requested
information and reopen issue. Thanks in advance.