如何获得PDB文件mscorlib.ni.lib(.NET Framework 3.5的) [英] How to get the PDB file for mscorlib.ni.lib (.Net Framework 3.5)

查看:835
本文介绍了如何获得PDB文件mscorlib.ni.lib(.NET Framework 3.5的)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

做了很多搜索后,我仍然无法获得问题的解决方案。

我有一个MDMP文件。调用堆栈显示它正在使用mscorlib.ni.dll。因此,要获得功能的信息,我需要得到它的PDB文件。

mscorlib.ni.dll的版本是2.0.50727.3655。 我相信它来自.NET Framework 3.5的。

由于mscorlib.ni.dll是由ngen.exe产生的本地优化的dll,所以我需要使用ngen.exe createpdb生成PDF此DLL。

  ngen.exe createpdbC:\ WINDOWS \组装\ ... \ mscorlib.ni.dllC:\ SymbolCache
 

下面是结果:

  1. 在我找不到ngen.exe文件夹C:\ WINDOWS \ Microsoft.NET \ Framework64 \ V3.5
  2. 在我能找到ngen.exe文件夹C:\ WINDOWS \ Microsoft.NET \ Framework64 \ V2,但它并没有createpdb选项
  3. 在我能找到ngen.exe文件夹中。C:\ WINDOWS \ Microsoft.NET \ Framework64 \ v4.0.30319和它支持createpdb选项,但它会报告错误
  

微软(R)CLR本机图像生成 - 版本4.0.30319.18408   版权所有(c)Microsoft公司。版权所有。无效   在本机映像标头中找到   C:\ WINDOWS \组装\ NativeImages_v2.0.507   7_64 \ mscorlib程序\ 5cd1c2848ff40eb0a8c149706ee394fa \ mscorlib.ni.dll。   未指定的错误(从HRESULT异常:0X80004005(E_FAIL))

所以,我不知道如何让PDB此mscorlib.ni.dll NET框架3.5。

你知道吗?

解决方案

我有同样的错误消息,直到我意识到我打电话ngen.exe从框架的 64 文件夹

。显然,mscorlib.ni.dll是不是64位。

所以我用了32位版本的ngen.exe从文件夹 C:\ WINDOWS \ Microsoft.NET \框架\ v4.0.30319 ,并成功生产出PDB。

然而,的路径mscorlib.ni.dll包括 ... \ NativeImages_v2.0.507 7_64 \ ... ,这表明它是64位的,所以这可能是一个不同的问题。

After doing a lot of search, I still couldn't get the solution for the question.

I have a mdmp file. The call stack shows it is using mscorlib.ni.dll. So to get the function information, I need to get its pdb file.

The version of mscorlib.ni.dll is 2.0.50727.3655. I believe it comes from .Net Framework 3.5.

Since mscorlib.ni.dll is the native optimized dll which is generated by ngen.exe, so I need to use ngen.exe createpdb to generate pdf for this dll.

ngen.exe createpdb "C:\Windows\assembly\...\mscorlib.ni.dll" "C:\SymbolCache"

Here is the result:

  1. I can't find ngen.exe in folder "C:\Windows\Microsoft.NET\Framework64\v3.5"
  2. I could find ngen.exe in folder "C:\Windows\Microsoft.NET\Framework64\v2", but it does not have createpdb option.
  3. I could find ngen.exe in folder "C:\Windows\Microsoft.NET\Framework64\v4.0.30319" and it does support createpdb option, but it reports error.

Microsoft (R) CLR Native Image Generator - Version 4.0.30319.18408 Copyright (c) Microsoft Corporation. All rights reserved. Invalid header found in native image 'C:\Windows\assembly\NativeImages_v2.0.507 7_64\mscorlib\5cd1c2848ff40eb0a8c149706ee394fa\mscorlib.ni.dll'. Unspecified error (Exception from HRESULT: 0x80004005 (E_FAIL))

So I have no idea how to get the pdb for this mscorlib.ni.dll of Net Framework 3.5.

Any idea?

解决方案

I had the same error message until I realized I call ngen.exe from the Framework64 folder. Apparently, the mscorlib.ni.dll was not 64-bit.

So I used the 32-bit version of ngen.exe from the folder C:\Windows\Microsoft.NET\Framework\v4.0.30319 and it successfully produced the PDB.

However, the path to your mscorlib.ni.dll includes ...\NativeImages_v2.0.507 7_64\..., which indicates it is 64-bit, so this might be a different issue.

这篇关于如何获得PDB文件mscorlib.ni.lib(.NET Framework 3.5的)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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