Windbg is a free source code-level debugging tool developed by Microsoft. Windbg can be used for kernel mode debugging and user mode debugging. It can also debug dump files. This article is about installing debugging tools for Windows. For more information, see my previous article. For dump file debugging by windbg, you can set the symbol file path and source file path through the menu, and set multiple paths.
1. Open a dump file
Open windbg, select "dump" from the menu [file] à [open crash dump], or open the doscommand window through cmd, switch to the directory where windbg is located, and use the command:
Windbg-z "D:/Lines2009-7-25-22-20-33-900.dmp"
-Z indicates the path
Figure 1.1 Use windbg to open the dump file
Load Dump File display
Figure 1.2 windbg Interface
2. Analyze the dump file
If the generated dump file is on the local machine, the dump file will contain the PDB file and source code path required for debugging. If the dump file is not on the local machine, you can use the windbg menu [file] à [Symbol file path] and [source file path] to set the PDB file path and source code path respectively. If the program involves DLL, You need to include all the PDB and source code paths involved in EXE and DLL. Run the following command:
! Analyze-V
The dump file is analyzed and the code line in which the program crashes is displayed:
Figure 1.3 analyze the dump file
This article from the csdn blog, reproduced please indicate the source: http://blog.csdn.net/alicehyxx/archive/2009/07/25/4380459.aspx