Need help interpreting data from Memory Profiler

Use this forum for questions on how to use .NET Memory Profiler and how to analyse memory usage.
Post Reply
SGu
Posts: 2
Joined: Fri Mar 20, 2009 9:09 pm

Need help interpreting data from Memory Profiler

Post by SGu » Fri Mar 20, 2009 9:43 pm

I am trying to find the source of a memory leak in my ASP.Net app using the .Net Memory Profiler version 3.1.

I have two snapshots each taken after one use (snapshot taken after closing browser) and a stress run (snapshot taken after stopping stress run). So now I have two snapshots to compare, and my problem there way too many classes which have the "Delta" column greater than 0!

How can I shorten the list of classes/instances to investigate?

The only columns that I see on the "Types" view are Namespace, Name, Live Instances Total, Live Instances Delta, Live instances sizes Total, Live instances sizes max, min and delta, and the last column is Unreachable.

This is for the Standard view (no other option is available in the drop down).

Any help greatly appreciated!

Thanks!

Andreas Suurkuusk
Posts: 1029
Joined: Wed Mar 02, 2005 7:53 pm

Post by Andreas Suurkuusk » Mon Mar 23, 2009 8:43 pm

There are a lot of instances created by the framework when profiling an ASP.NET application, so it can be a bit hard to identify the classes to investigate. In another post I provided some tips on ASP.NET profiling that you might find useful:
http://memprofiler.com/forum/viewtopic.php?t=1230

From your description it seems like you are attaching to the ASP.NET process. When attaching to a process, the profiler cannot provide as much data as when starting the ASP.NET process from the profiler. If it's possible, I would recommend that you try to run ASP.NET under the profiler.

Can you provide some more information on how the snapshots were collected? In the first case (closing the browser), did you collect a snapshot before requesting the ASP.NET pages and then one after you closed the browser? Are you able to locate classes that belong to your application (and not the framework)?
Best regards,

Andreas Suurkuusk
SciTech Software AB

SGu
Posts: 2
Joined: Fri Mar 20, 2009 9:09 pm

Post by SGu » Tue Mar 24, 2009 5:13 am

Yes, I did take a look at the post mentioned below, and it was helpful to get me started.

The snapshots were taken as follows (after first attaching to the w3wp process)
First snapshot -
1. Perform scenario (that results in leak) once.
2. Close browser.
3. Take a heap snapshot.

Second snapshot -
1. Start a mini load test that performs the scenario in #1 above repeatedly.
2. After about 10 minutes or so, stop the loadtest.
3. Take the second snapshot.

Yes, I do see several classes that belong to my app., and the problem is that there are quite a few of them!

Andreas Suurkuusk
Posts: 1029
Joined: Wed Mar 02, 2005 7:53 pm

Post by Andreas Suurkuusk » Tue Mar 24, 2009 10:23 pm

Have you tried to investigate any of the classes that belongs to your app and that have new instances? Even if you don't know exactly what class is responsible for the memory leak, the root paths of a class can provide hints on why you have so many new instances.

Without more information about your application it's hard to provide much more additional help. If you provide us with a session file, I might be able to give some you some additional hints. Please contact us at at support@scitech and we will send you information on how to provide us with a session file.
Best regards,

Andreas Suurkuusk
SciTech Software AB

Post Reply

Who is online

Users browsing this forum: No registered users and 24 guests