当前位置 : 主页 > 编程语言 > 其它开发 >

【Windbg Preview】Failed to load data access DLL, 0x80004005

来源:互联网 收集:自由互联 发布时间:2022-05-30
最近使用Windbg的时候一直在用Preview版本,感觉解析一下就能直接加载起环境来太爽了。不过最近遇到一个dump加载不起来了。 但是最近一次加载却失败了,尝试了很久也不行 Failed to l

最近使用Windbg的时候一直在用Preview版本,感觉解析一下就能直接加载起环境来太爽了。不过最近遇到一个dump加载不起来了。

但是最近一次加载却失败了,尝试了很久也不行

Failed to load data access DLL, 0x80004005
Verify that 1) you have a recent build of the debugger (6.2.14 or newer)
            2) the file mscordacwks.dll that matches your version of clr.dll is 
                in the version directory or on the symbol path
            3) or, if you are debugging a dump file, verify that the file 
                mscordacwks_<arch>_<arch>_<version>.dll is on your symbol path.
            4) you are debugging on supported cross platform architecture as 
                the dump file. For example, an ARM dump file must be debugged
                on an X86 or an ARM machine; an AMD64 dump file must be
                debugged on an AMD64 machine.

You can also run the debugger command .cordll to control the debugger's
load of mscordacwks.dll.  .cordll -ve -u -l will do a verbose reload.
If that succeeds, the SOS command should work on retry.

If you are debugging a minidump, you need to make sure that your executable
path is pointing to clr.dll as well.

从服务器上下载下来对应的dll加载也没有用

clr.dll
mscordacwks.dll
SOS.dll

最终发现Preview版本会自动加载很多dll 其中就有自动下载下来的SOS版本

||2:2:360> .chain
Extension DLL search Path:
    C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\WINXP;C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext;C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext\arcade;C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\pri;C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64;C:\Users\bianc\AppData\Local\Dbg\EngineExtensions;C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\150\Tools\Binn\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files\dotnet\;C:\Program Files (x86)\NetSarang\Xshell 7\;C:\Program Files\Microsoft VS Code\bin;C:\Program Files\Windows Kits\10\Debuggers\x64;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Users\bianc\AppData\Local\Microsoft\WindowsApps;C:\Users\bianc\.dotnet\tools
Extension DLL chain:
    D:\WorkTemp\Windb\Runtime\Server\clr.dll: image 4.7.3701.0, built Thu Sep  3 03:32:39 2020
        [path: D:\WorkTemp\Windb\Runtime\Server\clr.dll]
    D:\WorkTemp\Windb\Runtime\Server\SOS.dll: image 4.7.3701.0, API 1.0.0, built Thu Sep  3 03:22:41 2020
        [path: D:\WorkTemp\Windb\Runtime\Server\SOS.dll]
    C:\mysymbols\SOS_AMD64_AMD64_4.7.3701.00.dll\5F4FF3579ec000\SOS_AMD64_AMD64_4.7.3701.00.dll: image 4.7.3701.0, API 1.0.0, built Thu Sep  3 03:22:41 2020
        [path: C:\mysymbols\SOS_AMD64_AMD64_4.7.3701.00.dll\5F4FF3579ec000\SOS_AMD64_AMD64_4.7.3701.00.dll]
    ext: image 10.0.25111.1000, API 1.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext\ext.dll]
    CLRComposition: image 10.0.25111.1000, API 0.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext\CLRComposition.dll]
    MachOBinComposition: image 10.0.25111.1000, API 0.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext\MachOBinComposition.dll]
    ELFBinComposition: image 10.0.25111.1000, API 0.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext\ELFBinComposition.dll]
    dbghelp: image 10.0.25111.1000, API 10.0.6, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\dbghelp.dll]
    exts: image 10.0.25111.1000, API 1.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\WINXP\exts.dll]
    uext: image 10.0.25111.1000, API 1.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\winext\uext.dll]
    ntsdexts: image 10.0.25111.1000, API 1.0.0, 
        [path: C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2205.18001.0_x64__8wekyb3d8bbwe\amd64\WINXP\ntsdexts.dll]

猜测可能是自动加载的跟我们服务器上的部分Dll不匹配。所以导致了问题,那么换成正常版本的Windbg,然后手动依次加载从服务器上下载下来的对应版本。

0:000> .load D:\WorkTemp\Windb\Runtime\Server\SOS.dll
0:000> .load D:\WorkTemp\Windb\Runtime\Server\clr.dll
0:000> .cordll -lp D:\WorkTemp\Windb\Runtime\Server
CLR DLL status: Loaded DLL D:\WorkTemp\Windb\Runtime\Server\mscordacwks.dll
0:000> !eeversion

************* Symbol Loading Error Summary **************
Module name            Error
clr                    The system cannot find the file specified

You can troubleshoot most symbol related issues by turning on symbol loading diagnostics (!sym noisy) and repeating the command that caused symbols to be loaded.
You should also verify that your symbol search path (.sympath) is correct.
PDB symbol for clr.dll not loaded
4.7.3701.0 free
Server mode with 8 gc heaps
SOS Version: 4.7.3701.0 retail build

果然就好了

然后看一下加载目录

0:000> .chain
Extension DLL search Path:
    C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\WINXP;C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\winext;C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\winext\arcade;C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\pri;C:\Program Files (x86)\Windows Kits\10\Debuggers\x64;C:\Users\bianc\AppData\Local\Dbg\EngineExtensions;C:\Program Files (x86)\Windows Kits\10\Debuggers\x64;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\150\Tools\Binn\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files\dotnet\;C:\Program Files (x86)\NetSarang\Xshell 7\;C:\Program Files\Microsoft VS Code\bin;C:\Program Files\Windows Kits\10\Debuggers\x64;C:\Users\bianc\AppData\Local\Microsoft\WindowsApps;C:\Users\bianc\.dotnet\tools
Extension DLL chain:
    D:\WorkTemp\Windb\Runtime\Server\clr.dll: image 4.7.3701.0, built Thu Sep  3 03:32:39 2020
        [path: D:\WorkTemp\Windb\Runtime\Server\clr.dll]
    D:\WorkTemp\Windb\Runtime\Server\SOS.dll: image 4.7.3701.0, API 1.0.0, built Thu Sep  3 03:22:41 2020
        [path: D:\WorkTemp\Windb\Runtime\Server\SOS.dll]
    ELFBinComposition: image 10.0.22621.1, API 0.0.0, 
        [path: C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\winext\ELFBinComposition.dll]
    dbghelp: image 10.0.22621.1, API 10.0.6, 
        [path: C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\dbghelp.dll]
    exts: image 10.0.22621.1, API 1.0.0, 
        [path: C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\WINXP\exts.dll]
    uext: image 10.0.22621.1, API 1.0.0, 
        [path: C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\winext\uext.dll]
    ntsdexts: image 10.0.22621.1, API 1.0.0, 
        [path: C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\WINXP\ntsdexts.dll]

应该就是自动加载的那个SOS的版本跟服务器上的匹配不上导致的。

上一篇:关于ThreadLocal最直白的解释
下一篇:没有了
网友评论