Troubleshoot ASP.net possible memory leak

2019-08-03 19:34发布

It looks like there is a possible memory leak with one of our web applications. w3wp.exe is taking about 1.5gb of RAM and our web services are returning an error saying that it is out of memory. Is there a way to determine which application is causing the excessive memory or profile the actively running websites to see what the cause of the memory issue is?

I would post this on Server Fault, but I am more interested in a way of debugging the application to see where the fault is. I can run the websites locally and w3wp.exe does not take excessive amounts of RAM. These are active websites / web services that are in constant use, so I am assuming that the problem will only show up with excessive load.

3条回答
beautiful°
2楼-- · 2019-08-03 20:12

Watch this episode of dnrTV with Tess Ferrandez for some pointers on using WinDBG and other tools to analyze a memory dump - she makes it look really easy!

查看更多
冷血范
3楼-- · 2019-08-03 20:24

You could try a copy of Red Gate's Memory Profiler.

Trying to guess the memory leak in your app will take forever. A profiling tool will show you exactly where the problem is without all the pesky trial and error.

查看更多
做个烂人
4楼-- · 2019-08-03 20:28

The Debug Diagnostics Toolkit is designed exactly for this purpose.

There are a fair few articles around on how to use the toolkit:

查看更多
登录 后发表回答