NTDLL的错误符号(错误3)。中止

时间:2014-10-24 18:14:07

标签: windbg

什么可能导致错误:

Bad symbols for NTDLL (error 3). Aborting.

使用!cs命令时?

我正在分析键盘强制完整转储并设置了MS符号服务器的符号路径。

lml不会将ntdll列为已加载

.sym嘈杂,重新加载显示:

3: kd> .reload ntdll

"ntdll" was not found in the image list.
Debugger will attempt to load "ntdll" at given base 00000000`00000000.

Please provide the full image name, including the extension (i.e. kernel32.dll)
for more reliable results.Base address and size overrides can be given as
.reload <image.ext>=<base>,<size>.
DBGENG:  ntdll - Partial symbol image load missing image info
DBGHELP: No header for ntdll.  Searching for dbg file
DBGHELP: .\ntdll.dbg - file not found
DBGHELP: ntdll missing debug info.  Searching for pdb anyway
DBGHELP: Can't use symbol server for ntdll.pdb - no header information available
DBGHELP: ntdll.pdb - file not found

DBGHELP: ntdll - no symbols loaded
Unable to add module at 00000000`00000000
3: kd> .reload nt

DBGHELP: nt - public symbols  
        c:\symbols\ntkrnlmp.pdb\BF9E190359784C2D8796CF5537B238B42\ntkrnlmp.pdb

是否应该在lm命令中列出ntdll? 加载符号或运行这些命令是否需要特殊的东西?

此外,我也很好奇为什么我不能在强制/完整系统转储中转储所有线程:

3: kd> ~* k
   ^ Syntax error in '~* k'

我是否只是无法正确设置windbg,或者这些命令是否适用于其他类型的转储?

1 个答案:

答案 0 :(得分:1)

之前您似乎已完成用户模式调试。现在您处于内核模式,您可以从x: kd>提示中看到。

内核模式调试与用户模式调试有些不同。最重要的恕我直言:并非所有的应用程序内存(虚拟内存)都可用,只是转储(物理内存)时RAM中的部分。工作集(特定进程的物理内存)。

您可以使用!process 0 0 <exename>

搜索您的可执行文件
0: kd> !process 0 0 NotMyFault.exe
PROCESS ff3b58f0  SessionId: 0  Cid: 05ac    Peb: 7ffde000  ParentCid: 039c
    DirBase: 018c02e0  ObjectTable: e165d728  HandleCount:  35.
    Image: NotMyfault.exe

不幸的是,此时无法进行通配符搜索。然后,您可以使用.process <process>切换到该流程:

0: kd> .process ff3b58f0
Implicit process is now ff3b58f0

要查看主题使用!process <process> 2

0: kd> !process ff3b58f0 2
PROCESS ff3b58f0  SessionId: 0  Cid: 05ac    Peb: 7ffde000  ParentCid: 039c
    DirBase: 018c02e0  ObjectTable: e165d728  HandleCount:  35.
    Image: NotMyfault.exe

        THREAD ff1d4020  Cid 05ac.05b0  Teb: 7ffdd000 Win32Thread: e1c6e2b0 RUNNING on processor 0

接下来,使用!thread <thread>获取类似于~的输出:

0: kd> !thread ff1d4020
THREAD ff1d4020  Cid 05ac.05b0  Teb: 7ffdd000 Win32Thread: e1c6e2b0 RUNNING on processor 0
IRP List:
    81942f68: (0006,0094) Flags: 40000000  Mdl: 00000000
Not impersonating
DeviceMap                 e169ffd0
Owning Process            0       Image:         <Unknown>
Attached Process          ff3b58f0       Image:         NotMyfault.exe
Wait Start TickCount      13575          Ticks: 0
Context Switch Count      653            IdealProcessor: 0                 LargeStack
UserTime                  00:00:00.000
KernelTime                00:00:00.078
Win32 Start Address NotMyfault (0x01002945)
Start Address kernel32!BaseProcessStartThunk (0x7c8106f5)
Stack Init f36f1000 Current f36f030c Base f36f1000 Limit f36ec000 Call 0
Priority 9 BasePriority 8 PriorityDecrement 0 DecrementCount 16
ChildEBP RetAddr  Args to Child              
f36f0ad0 8052036a 00000050 81617000 00000001 nt!KeBugCheckEx+0x1b (FPO: [Non-Fpo])
f36f0b38 80544578 00000001 81617000 00000000 nt!MmAccessFault+0x9a8 (FPO: [Non-Fpo])
f36f0b38 fca6161d 00000001 81617000 00000000 nt!KiTrap0E+0xd0 (FPO: [0,0] TrapFrame @ f36f0b50)
f36f0bd8 fca61a24 81942f68 f36f0c1c fca61b26 myfault+0x61d
f36f0be4 fca61b26 80fa7350 00000001 00000000 myfault+0xa24
f36f0c1c 804ef18f 80f7b600 81942f68 806e6428 myfault+0xb26
...

如果您在加载符号时遇到问题,请在使用.reload /user后尝试.process <process>