Questions tagged [out-of-memory]

An error or exception which is thrown when a program makes a request for memory that cannot be satisfied.

An error or exception which is thrown when a program makes a request for memory that cannot be satisfied.

Such a system will be unable to load any additional programs and since many programs may load additional data into memory during execution, these will cease to function correctly. This occurs because all available memory, including disk swap space, has been allocated.

Out-of-memory error may occur also in programming languages with automatic memory management. In this case, the automatic management system (e.g. garbage collector) is not able to reclaim enough contiguous memory to satisfy the allocation rate of the application.

8109 questions
1386
votes
44 answers

Strange OutOfMemory issue while loading an image to a Bitmap object

I have a ListView with a couple of image buttons on each row. When the user clicks the list row, it launches a new activity. I have had to build my own tabs because of an issue with the camera layout. The activity that gets launched for the result…
Chrispix
  • 17,941
  • 20
  • 62
  • 70
1242
votes
34 answers

Dealing with "java.lang.OutOfMemoryError: PermGen space" error

Recently I ran into this error in my web application: java.lang.OutOfMemoryError: PermGen space It's a typical Hibernate/JPA + IceFaces/JSF application running on Tomcat 6 and JDK 1.6. Apparently this can occur after redeploying an application a…
Chris
  • 632
  • 4
  • 11
  • 18
948
votes
22 answers

Error java.lang.OutOfMemoryError: GC overhead limit exceeded

I get this error message as I execute my JUnit tests: java.lang.OutOfMemoryError: GC overhead limit exceeded I know what an OutOfMemoryError is, but what does GC overhead limit mean? How can I solve this?
Mnementh
  • 50,487
  • 48
  • 148
  • 202
723
votes
38 answers

Generate an integer that is not among four billion given ones

I have been given this interview question: Given an input file with four billion integers, provide an algorithm to generate an integer which is not contained in the file. Assume you have 1 GB memory. Follow up with what you would do if you have…
SecureFish
  • 2,391
  • 7
  • 32
  • 43
562
votes
31 answers

How to deal with "java.lang.OutOfMemoryError: Java heap space" error?

I am writing a client-side Swing application (graphical font designer) on Java 5. Recently, I am running into java.lang.OutOfMemoryError: Java heap space error because I am not being conservative on memory usage. The user can open unlimited number…
Eugene Yokota
  • 94,654
  • 45
  • 215
  • 319
531
votes
34 answers

Node.js heap out of memory

Today I ran my script for filesystem indexing to refresh RAID files index and after 4h it crashed with following error: [md5:] 241613/241627 97.5% [md5:] 241614/241627 97.5% [md5:] 241625/241627 98.1% Creating missing list... (79570 files…
Lapsio
  • 6,384
  • 4
  • 20
  • 26
527
votes
15 answers

What is a StackOverflowError?

What is a StackOverflowError, what causes it, and how should I deal with them?
Ziggy
  • 21,845
  • 28
  • 75
  • 104
334
votes
10 answers

How do you add swap to an EC2 instance?

I'm currently running an ec2 micro instance and i've been finding that the instance occasionally runs out of memory. Other than using a larger instance size, what else can be done?
ajtrichards
  • 29,723
  • 13
  • 94
  • 101
290
votes
14 answers

Spark java.lang.OutOfMemoryError: Java heap space

My cluster: 1 master, 11 slaves, each node has 6 GB memory. My settings: spark.executor.memory=4g, Dspark.akka.frameSize=512 Here is the problem: First, I read some data (2.19 GB) from HDFS to RDD: val imageBundleRDD =…
Hellen
  • 3,472
  • 5
  • 18
  • 25
213
votes
9 answers

Unable to execute dex: GC overhead limit exceeded in Eclipse

When I downloaded the Git project OsmAnd and went to compile it, Eclipse returned these errors: [Dex Loader] Unable to execute dex: GC overhead limit exceeded [OsmAnd] Conversion to Dalvik format failed: Unable to execute dex: GC…
DavyJonesUA
  • 2,309
  • 2
  • 18
  • 21
185
votes
7 answers

"java.lang.OutOfMemoryError: PermGen space" in Maven build

I'm getting this error while building Maven project, I increased MAVEN_OPTS but all the same, I found some similar posts but they are refering to something else. How do I fix this? The system is out of resources. Consult the following stack trace…
Gandalf StormCrow
  • 25,788
  • 70
  • 174
  • 263
165
votes
5 answers

What is the maximum amount of RAM an app can use?

I am quite curious about this question concerning the memory management of the Android operating system so I hope for a quite detailed answer on that topic. What I would like to know: What is the maximum amount of memory (in megabytes /…
Philipp Jahoda
  • 50,880
  • 24
  • 180
  • 187
162
votes
15 answers

"java.lang.OutOfMemoryError : unable to create new native Thread"

We are getting "java.lang.OutOfMemoryError : unable to create new native Thread" on 8GB RAM VM after 32k threads (ps -eLF| grep -c java) However, "top" and "free -m" shows 50% free memory available. JDk is 64 bit and tried with both HotSpot and…
Deepak Tewani
  • 1,687
  • 2
  • 11
  • 7
160
votes
13 answers

java.lang.OutOfMemoryError: bitmap size exceeds VM budget - Android

I developed an application that uses lots of images on Android. The app runs once, fills the information on the screen (Layouts, Listviews, Textviews, ImageViews, etc) and user reads the information. There is no animation, no special effects or…
Daniel Benedykt
  • 6,496
  • 12
  • 51
  • 73
145
votes
8 answers

java.lang.OutOfMemoryError: Java heap space in Maven

When I run maven test, java.lang.OutOfMemoryError happens. I googled it for solutions and have tried to export MAVEN_OPTS=-Xmx1024m, but it did not work. Anyone know other solutions for this problem? I am using maven 3.0 Paste the error message here…
zjffdu
  • 25,496
  • 45
  • 109
  • 159
1
2 3
99 100