Solved

asp.net suspected memory leak issue

Posted on 2013-11-22
3
386 Views
Last Modified: 2013-12-02
Hi,

We are having a  asp.net application deployed on windows 2008 server.
The users are not able to log in to the application all of a sudden. It stays on the login page forever without logging in.
I checked perfmon.exe.
I added counters for private bytes, bytes in all heaps and # current logical threads.

bytes in all heaps and current logical threads remain steady.
I do not see anything for private bytes counter.
Why does it not show any line in for this counter? What does it mean?

if bytes in all heaps remains constant, it might not be a managed memory issue. The problem might be with the unmanaged memory.
How do i detect this issue?

In the asp.net debug mode(development machine), can i see if any objects are not disposed?

Thanks
0
Comment
Question by:shahjagat
  • 2
3 Comments
 
LVL 16

Accepted Solution

by:
Stephan earned 250 total points
ID: 39671297
To answer your question if you can see it in debug mode: No, unfortunatly not.

When you have a memory leak, your w3wp process will constantly grow. It depends how big the issue is to easily see it.

Memory issues is the hardest piece to fix.

There are some paid products that will really help you.
Take a look at ANTS Memory profiler or JetBrains Memory profiler.
On this there is a trial period on this product to see if it really helps you out.

If you really want to do this without the products you can take a look at this article that will help you get through the process of locating Managed or Unmanaged memory problems.
http://www.codeproject.com/Articles/19490/Memory-Leak-Detection-in-NET
0
 

Author Comment

by:shahjagat
ID: 39681120
stephanonline,


After a restart of the server and recycle of application pools, our application is running.
I am using performance monitor and added a few counters
privatebytes, bytes in all heaps, arrival rate, requests/sec, # of exceptions thrown per sec etc.

Before restart, we made 2 changes
First change was removing some parts of code which we suspected were causing issues.
Second - our server had only 2 GB of hard disk space left. We cleared lots of log files and some backup files.

After restart of the server, the application started to run good.

Is the low disk space a reason for the issue which we experienced? If yes, why did it not affect our other applications which were hosted on the same server?

Do you suggest any other counters in addition to the above mentioned counters that i added to performance monitor? I want to continue monitoring this application for a few weeks.

Thanks
0
 
LVL 16

Expert Comment

by:Stephan
ID: 39683502
Low disk space can be an issue, it mostly depends on what your application does on how it will react to it.

Here you find a list of counters you can use that will help:
http://msdn.microsoft.com/en-us/library/x2tyfybc(v=vs.110).aspx
http://msdn.microsoft.com/en-us/library/ekec01h3(v=vs.110).aspx
http://msdn.microsoft.com/en-us/library/9tyc2s04(v=vs.110).aspx
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
In this Article, I will provide a few tips in problem and solution manner. Opening an ASPX page in Visual studio 2003 is very slow. To make it fast, please do follow below steps:   Open the Solution/Project. Right click the ASPX file to b…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now