Debugging Beyond Visual Studio – WinDbg
Getting started with WinDbg:
1. Download the Debugging Tools for Windows from the Microsoft website
We recommend you install WinDbg Preview as it offers more modern visuals, faster windows, a full-fledged scripting experience, built with extensible debugger data model front and center.
![]()
2. When clicking Download from the Microsoft Store, a prompt will appear, select “Get”
![]()
3. Windows will start the download and installation process. A prompt will confirm installation status.
![]()
4. Select to “Pin to Start,” close windows by clicking “X” on the top right of Window.
![]()
5. Set the Windows Symbol Server path in File > Settings > Symbol path (see example below)
![]()
6. Go to your Start menu, select the WinDbg Preview to launch the application
7. The WinDbg initial view
![]()
8. What is the difference between User Mode-Debugging and Kernel-Mode Debugging?
In User mode debugging, the code normally delegates to the system API’s to access hardware or memory. You typically are debugging a single executable, which is separated from other executables by the OS. Typical scenario is to isolate memory or application hang issues on Win32 desktop applications. In User mode, the debugger is running on the same system as the code being debugged.
In Kernel mode debugging, the code normally has unrestricted access to the hardware. Typical scenario is driver code developed for hardware devices. When debugging in Kernel mode you typically use two different systems. One system runs the code that is being debugged, and another runs the debugger, usually connected with a cable. Click here for additional information on Kernel mode debugging.
9. Advantages of WinDbg:
- Extensive numbers of commands and extensions.
- A useful tool to help understand OS and software running on the system being debugged.
- Lightweight and can be used in production as it has no dependency, only require an executable (.exe) to run.
- A useful tool to help isolate User or Kernel mode code that's difficult to troubleshoot on Windows.
10. Common User mode debugging commands:
.hh (Open WinDbg’s help)
![]()
Vertaget (Get the version of the target computer)
![]()
Symbol Path (Display or set symbol search path)
![]()
Version (Dump version info of debugger and loaded extension DLLs)
![]()
!ext.help(General extensions)
![]()
!analyze -v (Display information about the current exception or bug check; verbose)
![]()
11. Common Kernel mode debugging commands:
!analyze
![]()
!error (plus error code, e.g. “!error c0000005)
![]()
12. Useful links:
Debugging Using WinDbg Preview:
https://docs.microsoft.com/en-us/windows-hardware/drivers/debugger/debugging-using-windbg-preview
Getting Started with WinDbg Microsoft Docs:
https://docs.microsoft.com/en-us/windows-hardware/drivers/debugger/getting-started-with-windbg
Common WinDbg Commands:
http://windbg.info/doc/1-common-cmds.html
Elementary User-Mode Debugging:
https://microsoft.sharepoint.com/teams/bidpwiki/Pages1/Elementary%20User-Mode%20Debug.aspx
Debugging Beyond Visual Studio – WinDbg的更多相关文章
- Visual Studio 2010初学者的调试指南:Mastering Debugging in Visual Studio 2010 - A Beginner's Guide
Introduction In the software development life cycle, testing and defect fixing take more time than a ...
- 转:Remote debugging with Visual Studio 2010
Original URL http://www.codeproject.com/Articles/146838/Remote-debugging-with-Visual-Studio-2010 you ...
- Just-In-Time Debugging in Visual Studio 禁止VS在服务器上调试
To disable Just-In-Time debugging by editing the registry On the Start menu, search for and run rege ...
- How to debug .NET Core RC2 app with Visual Studio Code on Windows?
Simone Chiaretta (http://codeclimber.net.nz/archive/2016/05/20/How-to-debug-NET-Core-RC2-app-with-Vi ...
- 如何解决Visual Studio调试Debug很卡很慢
http://brightguo.com/make-debugging-faster-with-visual-studio/ Have you ever been frustrated by slow ...
- 用Visual Studio调试Windows和驱动程序
由于本人能力有限,翻译不足之处敬请谅解,欢迎批评指正:sunylat@163.com Visual Studio版本:Visual Studio 2015企业版,中文环境. MSDN原文:https: ...
- 使用Visual Studio 2013 调试 MASM 汇编程序!
原文地址:http://kipirvine.com/asm/debug/vstudio2013/index.htm Using the Microsoft Visual Studio 2013 Deb ...
- Oleg Sych - » Pros and Cons of T4 in Visual Studio 2008
Oleg Sych - » Pros and Cons of T4 in Visual Studio 2008 Pros and Cons of T4 in Visual Studio 2008 Po ...
- Pros and Cons of T4 in Visual Studio 2008
Oleg Sych - » Pros and Cons of T4 in Visual Studio 2008 Pros and Cons of T4 in Visual Studio 2008 Po ...
随机推荐
- 共创力咨询推出《静态代码分析(PCLint)高级实务培训》课程!
[课程背景] C/C++语言的语法非常灵活性,尤其是指针及内存使用,这种灵活性使代码效率比较高,但同时也使得代码编写具有较大的随意性,另外C/C++编译器不进行强制类型检查,也不对数据边界和有效性进行 ...
- Zabbix监控USG6300防火墙及交换机
1.登录防火墙直接在web上面配置SNMP,只读团体名.读写团体名.Trap接收主机.安全名,点击应用完成防火墙上面的SNMP配置,如果你的命令行敲得6,可以使用命令行敲,配置效果一样,交换机没有这么 ...
- More Moore and More than Moore
More Moore and More than Moore ——基于硅光电子学探讨摩尔定律的延续和发展 1965年4月,<电子学>杂志第114页上刊载了Intel创始人之一戈登·摩尔(G ...
- Python面试笔记三
1. 类继承 有如下的一段代码: python对象 如何调用类A的show方法了,方法如下: python对象 __class__方法指向了类对象,只用给他赋值类型A,然后调用方法show,但是用完了 ...
- ueditor富文本编辑器使用百度地图自定义动态地图组件及兼容https及http协议
ueditor富文本编辑器默认支持百度地图组件,但是如果导入动态地图后会加很多默认的地图组件在上面.如果需要自定义动态地图的组件则需要修改ueditor特定的html. ueditor百度地图组件所在 ...
- Python基础——8错误、调试和测试
捕捉错误 try: print('try...') r = 10 / int('2') print('result:', r) except ValueError as e: print('Value ...
- 软件设计之Deep Module(深模块)
类是不是越小越好?最近在读John Ousterhout的<A Philosophy of Software Design>,感到作者文笔流畅,书中内容具有启发性.这里摘要一部分内容,以供 ...
- Java之匿名内部类详解
前言 本文讲解Java中最后一种内部类,叫做匿名内部类.顾名思义,所谓的匿名内部类就是一个没有显式的名字的内部类,在实际开发中,此种内部类用的是非常多的. 匿名内部类 本质:匿名内部类会隐式的继承一个 ...
- vue 路由元信息
官方文档:路由meta元信息 前言: 在设置面包屑导航还有菜单栏的时候,路由的meta字段可以自定义我们需要的信息,然后路由跳转的时候,提供我们判断条件 文档: 定义路由的时候可以配置 meta 字段 ...
- vue 使用localStorage解决vuex在页面刷新后数据被清除的问题
通常,我们在使用vue编写页面时,会需要使用vuex在组件间传递(或者说共同响应)同一个数据的变化.例如:用户的登录信息. 下面,我们使用传递用户登录信息的例子来一步步解决这个问题. 首先,我们的第一 ...