[PowerShell Script] Chart and Statistics from Top 20 Objects Leaking

  If you want to know the top 20 objects associated with the GC Handles that are leaking, you have manual work to do. Think about it: a)    Run GCHandleLeaks and wait… it’s going to take time. b)    Get the objects’ instances from the handles. c)    Count and classify them. d)    Get the 20 objects…

9

[PowerShell Script] PowerDbg v4.0 – Using PowerShell to Control WinDbg

Good news! Here’s the newest PowerDbg library. This version is more stable and has more features.  Let me tell you about them and how to install it.   New Features    – Send-PowerDbgCTRL-BREAK / Send-PowerDbgResumeExecution   If you’re wondering why do you need these cmdlets I can see at least one scenario: software testing. For…

3

[PowerShell Script] Downloading PDB for Specific Modules

A few weeks ago, during a laboratory with a customer, I found myself struggling to download the public symbol from a specific driver. Since driver is Kernel Mode if you get a User Mode dump from the application using the driver, you won’t be able to actually see and download the driver. If you have…

2

[PowerShell Script] PowerDbg v3.1 – Using PowerShell to Control WinDbg

    This new version has one more parser for !PrintException and a killer feature that my colleagues and myself have wanted since the beginning: PowerDbg, more specifically Send-PowerDbgCommand, which now has the ability to wait until a command finished its execution.  It means no more delays to wait for a command to be processed…

5

[PowerShell Script] Displaying the Call Stack for Inner and Hidden Exceptions

This script automates a technique I’ve been using for a long time whenever I need to see the stack for exceptions hidden in a call stack and if you are like me, you prefer to use an automated approach rather than a manual approach. I’m not going to write the technique here because Mike Stall…

7

[PowerShell Script] Isolating the Threads Consuming High CPU

When helping my customers with scenarios in which the symptom is high CPU, I very often end up with only a dump file from the application consuming high CPU and nothing else. When you have a high CPU scenario and you have dump files, you need a Performance Monitor log in order to see the…

10

[PowerShell Script] PowerDbg v2.3 – Using PowerShell to Control WinDbg

It has been a while since my previous blog post. I’ve been busy with other tasks, including the new PowerDbg version 2.3. There’s a lot of new stuff on this new version and my estimate is that about 80% of the most used Windbg commands have been covered so far. J Let me present the…

9

[PowerShell Script] Saving a Module from a .NET Method Call

This is my first script using the PowerDbg functions. It’s a good example of how to use PowerDbg to build your own scripts. PowerDbgScriptSaveModule.ps1 is the PowerShell version of my Windbg script Save_Module.txt   Actually it does more than the previous version: it automatically saves the module that uses a specific method call. Then you…

10

[PowerShell Script] PowerDbg – Using PowerShell to Control WinDbg

[Note: According to Lee Holmes (one of the PowerShell creators) recommendation I changed the name convention. The images were not updated.]   Sometime ago a colleague of mine, Vandy Rodrigues, from the Messaging team, was enthusiastic to tell me about PowerShell and why I should learn it. I must admit to my readers that my…

11