分析内存转储找到泄漏 [英] Analyzing memory dump to find leak

查看:362
本文介绍了分析内存转储找到泄漏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一个c#.NET应用程序,它有一个内存泄漏。我使用procdump从运行的应用程序的实例从生产机器获取内存转储。生产机器运行32位Windows XP和.NET 4.0。

We have a c# .NET application that has a memory leak in it. I used procdump to get a memory dump from a running instance of the application from a production machine. The production machine is running 32 bit Windows XP, and .NET 4.0.

exe config设置为.net 4.0

The exe config is set to .net 4.0

<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0" />

当我把转储到我的dev盒子,windows 8.1 64位,并打开它与VS 2013 dump最初打开得很好。但是,当我点击调试管理内存操作时,我收到以下错误消息:

When I pull the dump to my dev box, windows 8.1 64bit, and open it with VS 2013 the dump is initially opened fine. However, when I click the Debug Managed Memory action I get the following error message:


支持在此过程中使用的CLR版本。

Memory analysis is not supported for the CLR version used in this process.

我是新修复Windows和托管内存环境中的内存泄漏,旁边没有涉及的工具。我做了一个google搜索的错误,我得到,没有找到任何东西。任何帮助是赞赏。我很抱歉,如果我缺少一些明显的东西 - Junior Dev这里: - )

I'm new to troubleshooting memory leaks in Windows and managed memory environments, and know next to nothing about the tools involved. I did a google search for the error I get, and didn't find anything. Any help is appreciated. I apologize if I am missing something obvious - Junior Dev here :-)

推荐答案

我不知道如果procdump可以使用在.NET中找到内存泄漏。我尝试的一个有效的方法是:使用Windbg和SOS。有两个帖子解释如何使用Windbg + SOS来跟踪.NET内存泄漏:

I don't know if procdump can be used to find a memory leak in .NET. One effective way I tried is: using Windbg and SOS. There are two posts explains how to use Windbg+ SOS to track .NET memory leaks:


  1. 你在哪里泄漏? [使用WinDbg,SOS和GCRoot诊断.NET内存泄漏]

  2. 使用windbg调试使用内存转储的托管代码内存泄漏

  1. Where's your leak at? [Using WinDbg, SOS, and GCRoot to diagnose a .NET memory leak]
  2. Debugging managed code memory leak with memory dump using windbg

如果您不喜欢Windbg,该工具 DebugDiag 也是跟踪内存泄漏的非常有效的工具。

If you don't like Windbg, the tool DebugDiag is also very effective tool in tracking down memory leaks.

这篇关于分析内存转储找到泄漏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆