GDI memory leak? RRS feed

  • Question

  • User-423920201 posted
    Hi - we've got a long-standing bug in our ASP.NET application. 

    The memory trace below shows what happens over approx a 3 minute period. First the processor shoots up, then the memory starts piling up. The server shots down serving pages for a couple of minutes, then IIS kicks in and recycles the worker process. The trace points to a non-managed code problewm I think.

    I can't reproduce this problem in our test ewnvironment, and it's happening at least once per hour on each of our 5 web servers.

    I'v got no idea how to find out what page or function starts this problem off... I've used the ".net memort profiler" tool, and all it tells me that the memory is not used by managed code.

    The only really "advanced" features of .NET we use are the GDI+ libraries - we re-size and manipulate uploaded jpgs - is it possible that GDI is causing the problem?

    Any help would be appreciated.

    Thursday, November 3, 2005 6:41 AM

All replies

  • User-1385434563 posted
    I've had problems with raster/bit maps and memory. What size are your jpgs, what type are they - compressed/uncompressed. How much memory does the server have available? What error messages do you get in the event handler?
    Friday, November 4, 2005 4:19 AM
  • User-423920201 posted
    The Jpgs are uploaded by the public, so I don't exactly what size or format they are! I don't get any error from the code - the server just hangs. I'm not 100% sure it's originating from the image manipulation code...
    Friday, November 4, 2005 11:44 AM