outofmemoryexception

OutOfMemory exception

Hi, 1) What are the possible reasons of OutofMemory exception. 2) Memory allocations should be handled by GC. 3) How much memory is allocated/Available to normal .Net/C# application In our application it comes at different places like Stream.ReadToEnd() and DataTable.WriteXml(Memory stream) function. *) Envoirment is .Net C# ...

Java memory leak

Has anybody used Eclipse memory manager to detect memory leak in java codes? Can anybody recommend a good place to look for information regarding using memory manager? I read something online, it suggests that i need to let the program run until it crashes (out of memory error occurs), which will generates a crash report. Then use the me...

Linux optimistic malloc: will new always throw when out of memory?

I have been reading about out of memory conditions on Linux, and the following paragraph from the man pages got me thinking: By default, Linux follows an optimistic memory allocation strategy. This means that when malloc() returns non-NULL there is no guarantee that the memory really is available. This is a really bad bug. In case it...

OutOfMemoryException during remote method call

Hi, Iam getting OutOfMemoryException while making remote method call. "RemoteEntity.SetLocalStore(DATASET);" passed value is dataset. Note Size of dataset is 38mb Envoirment c# VS2008 Thanks Code : private void backgroundSync_DoWork(object sender, DoWorkEventArgs e) { backgroundSync.ReportProgress(...

Why am I getting an Out of Memory Error doing ASP .NET Excel Interop?

This was working..and I moved the disposal code to the finally block, and now it fails every time. I have a test spreadsheet with 4 records, 6 columns long. Here is the code I'm using to bring it in. This is ASP .Net 3.5 on IIS 5 (my pc) and on IIS 6 (web server). It blows up on the line right before the catch: "values = (object[,])ran...

Linq to Entities and SQL Server 2008 FileStream

Backend: SQL Server 2008 database with FileStream enabled Data Access: Linq to Entities I have thousands of pdf's that currently reside on a file server. I would like to move these pdf's off of the file server and into a SQL Server 2008 database so that I can manage them easier. As a proof of concept (ie - to ensure that the new FileS...

Is it possible to catch out of memory exception in java?

I'm developing a program that would require huge amount of memory, and I want to catch when out-of-memory exception happens. I had heard this is not possible to do, but curious if there is any development on this end. ...

VB6 App Calling .NET DLL OutOfMemory Exception

We have a VB6 app that calls out to a .NET DLL. Occasionally, after the VB6 app has been running for a long time and has called the .NET code a lot, the .NET side of things throws an OutOfMemory exception, even though there is plenty of memory available on the machine. The VB6 memory space is also no where near it's limit. Does the .NE...

LinqToSql InsertOnSubmit memory leak?

I am trying to isolate the source of a "memory leak" in my C# application. This application copies a large number of potentially large files into records in a database using the image column type in SQL Server. I am using a LinqToSql and associated objects for all database access. The main loop iterates over a list of files and insert...

Why is "java.lang.OutOfMemoryError: Java heap space" not caught?

I have a thread in a Java web application that causes a java.lang.OutOfMemoryError: Java heap space exception, but the try/catch block does not catch the error. Sample code: private void doSomeWork() { try { processData(); //Causes OutOfMemoryError System.out.println("This line does not execute"); } ...

Maven throws "java.lang.OutOfMemoryError"

Hi, I'm compiling an open source project with "mvn install" but ended up with java.lang.OutOfMemoryError: Java heap space. I tried to execute java -Xmx256m but the output was java synopsis which indicated it's an invalid command. I'm using jdk1.5.0_08, any ideas why this is happening? Thanks, ...

Should I call GC.Collect immediately after using the large object heap to prevent fragmentation

My application does a good deal of binary serialization and compression of large objects. Uncompressed the serialized dataset is about 14 MB. Compressed it is arround 1.5 MB. I find that whenever I call the serialize method on my dataset my large object heap performance counter jumps up from under 1 MB to about 90 MB. I also know that un...

Postgresql OutOfMemory with Criteria.scroll() in Hibernate with 2M records

I am running a Criteria.scroll() on PostgreSQL on a DB containing 2M records. The memory keeps increasing and finally it generates an OutOfMemoryException. Please can you advice how to fix this. Postgresql DB version: 8.4 Postgresql Driver Used: postgresql-8.4-701.jdbc4.jar Is there some known issue with Hibernate scroll() in Pos...

win32 window in WPF

Recently our application encountered a strange problem. The application has a win32 window in the WPF window, when resize the WPF window, the problem occurred. StackTrace: Exception object: 0000000002ab2c78 Exception type: System.OutOfMemoryException InnerException: <none> StackTrace (generated): SP IP Function 00...

OutOfMemoryException when I hit 1GB

Does anyone know why I would get an OutOfMemoryException when TaskMgr.exe says my process is only taking up ~1GB of memory? ...

main java.lang.OutOfMemoryError: Java heap space

My code is doing things like this: for(SomeObject so : someObjects) { Blah b = so; NewObject n = dao.GetNO(b.23); } i.e. it is creating a new variable inside the for loop on each iteration. Could this be the cause of the out of memory issue? The error reported by Netbeans: Caused by: java.lang.OutOfMemoryError: Java heap space ...

Advice on solving OutOfMemoryExceptions for CF

My CF application has a very customized UI, using lots of images as UI elements. The UI feels a lot more smooth when these bitmaps are kept in memory. When they're loaded on demand, the UI is slow and I can see the buttons appearing one by one, which looks very poor. For a long time this went pretty well, but recently I've found the appl...

OutOfMemoryException with Clipboard.GetData and PRTSC

Hi all, I'm using : SendKeys.SendWait("+{PRTSC}"); InteropBitmap interopBitmap = System.Windows.Clipboard.GetData(System.Windows.DataFormats.Bitmap) as InteropBitmap; On my computer, everything is ok. On another computer, I get an OutOfMemoryException. Why ? How to solve it ? Thanks in advance for your answer ...

OutOfMemory exception appears while scrolling the list of images

I have a list of 70 text items with image icons(which are stored in drawables folder). If I launch application the first time and scroll the list slowly - the exception doesn't occur. When the application is launched the first time and I scroll the list with 'fling' action the following exception occurs: java.lang.OutOfMemoryError: bi...

How to avoid memory leaks in frame animation?

I've created simple test app with one activity. The activity contains frame animation. The total size of images in frame animation(riffle_forward_anim) is about 1MB. Here is the code I use to load animation: public class MainScreen extends Activity { /** Called when the activity is first created. */ private ImageView imgForward; priv...