Debugging Toolbox

Windbg scripts, debugging and troubleshooting tools and techniques to help you isolate software problems.

Browse by Tags

Tagged Content List
  • Blog Post: Tools for Your Debugging Toolbox

    This article was just updated to include an internal Microsoft tool that is now public. There are many free tools used to troubleshoot and debug software. Below I present a list of the tools that my peers and I use most of the time. Though most of the tools below are free Microsoft tools, not all...
  • Blog Post: Top Things to Consider When Troubleshooting Complex Application Issues

    1- For reactive incidents: “Bring the engineer onsite because it is going to be easier to isolate the problem.” This is the most common misconception I’ve heard. Let me explain: most complex problems require deep debugging sessions. Collecting the necessary information is the easy...
  • Blog Post: New Debugging Book – Windows Debugging Notebook: Essential User Space WinDbg Commands

    A reference book for technical support and escalation engineers troubleshooting and debugging complex software issues. The book is also invaluable for software maintenance and development engineers debugging Windows applications and services. Do you want to know more about this book? Check out...
  • Blog Post: PSSCOR2, the Superset of SOS.DLL is Now Public!!!

    Whenever I’m debugging with customers watching it’s inevitable: they always ask me what this PSSCOR2.dll extension is. The next question is always if PSSCOR2.DLL is going to be public. PSSCOR2.DLL is a superset of SOS.DLL and has much more commands and variations! The good news is that yes, now PSSCOR2...
  • Blog Post: XPerf Tool – Why Can’t You Live Without It?

    Israel Burman (Israel is one of the ADPlus creators and the guy who taught me the XPerf tool) and Mario Hewardt told me I should blog about the XPerf tool. Although I’m new to this tool I decided to follow their suggestions because I believe you’re going to wonder how you could live without using...
  • Blog Post: Special Command—Unassembling code with u, ub and uf

    When debugging sooner or later you will need to disassemble code to get a better understanding of that code. By disassembling the code, you get the mnemonics translated from the 0s and 1s that constitute the binary code. It is a low level view of the code, but a higher level than seeing just numbers...
  • Blog Post: Special Command—Using .dump/.dumpcab to Get Dumps and Symbols from Production Servers

    Using WinDbg you can create a dump file from an application running, for instance, in a production server. After collecting the dump file, you can load it in another machine and debug it. However, to be more effective during your debugging session you need symbols . Thus, thinking about it, here's the...
  • Blog Post: Special Command—Using !for_each_frame to Run Commands

    !for_each_frame is a favorite among debuggers. It's a very flexible and powerful command that enables you to run commands for each frame of the call stack. You can use basically any command. For instance, let’s say you want to see all local variables from each frame of a specific stack. Of course...
  • Blog Post: [PowerShell Script] Statistics from .NET Applications

    This script is more a template to show you how to use PowerDbg. I must say the idea is from my teammate Aaron Barth! This script collects information from all threads running managed code and gives the user statistics by threads like: - CLR stack. - Managed objects from the stack. ...
  • Blog Post: Special Command—Parsing Strings, Files, and Commands Output Using .foreach

    This is by far one of the most powerful WinDbg commands. Even if you don’t create scripts, you’ll benefit from this command. It’s powerful because it’s flexible. You can use it for a huge variety of operations. The .foreach token parses the output of one or more debugger commands and uses each...
  • Blog Post: Special Command—Parsing Commands Using .shell

    Finally I’m writing about this command. I love it! It’s so powerful! .shell command launches a shell process and redirects its output to the debugger or to a specified file. Usage: .shell [ Options ] [ ShellCommand ] .shell -i InFile [ -o OutFile [ -e ErrFile ]] [ Options ] ShellCommand According...
  • Blog Post: Special Command—How to See Different Call Stacks Only? !uniqstack

    I’ve been travelling a lot in the US and Latin America: that’s why you haven’t seen any new posts coming. Now I’m back! OK, just for a while, but it’s enough to write more articles. By the way, Buenos Aires (Argentina) is a beautiful place to know! J This post introduces a command that is not well...
  • Blog Post: Special Command—Searching the Call Stack for Symbols or Modules Using !findstack

    During your debugging session, you may find yourself trying to identify if a specific symbol or module appears in one or more threads. There’s more than one way to do that, and here I covert it in the simplest way: !findstack This command accepts the following arguments: Symbol Specifies...
  • Blog Post: Special Command: Using s to Explore The Memory

    Very often I found myself scanning the stack or the entire virtual memory for the process to find information that may help me. This information may be strings, DWORDS, bytes, chars, etc… To accomplish this you should use the s command. Here I exemplify how you can use it to scan the memory...
  • Blog Post: Special Command: Using dv to See the Local Variables

    The dv command stands for display variables. It’s easy to memorize. The reality , though, is in the trenches you won’t use the standard format of dv because it doesn’t give you enough (or much) information. Here is the way I use this command: dv /i /t /V /i Causes the display to...
  • Blog Post: Special Command: Analyzing the Memory and Stack Using the dp* Command

    When you need to see the raw call stack and memory, you have plenty of options. You can even leverage the WinDbg GUI to see them . Here I’m going to show you how to do that. dpa <address> L <range> dpa <startAddress> <endAddress> Using this command allows you...
  • Blog Post: Special Command: Analyzing and Reconstructing the Stack Using the k* Command and Its Variations

    I’m starting a new series of articles focused on explaining special commands and showing how they can be used. You can read about WinDbg commands using the WinDbg documentation ; however, sometimes you want to see the output of a specific command or you want to know when to use a specific command variation...
  • Blog Post: [Windbg Script] Digging the Call Stack

    Windbg has a lot of commands and command variations, so sometimes you may forget some of them, like when you need to dig a call stack to extract more information. Or maybe you remember the commands to get the call stack details, but you need to make sure you get the entire stack. Or yet you may want...
Page 1 of 1 (18 items)