EPiWiki.se  - EPiServer notes shared with others
 

StackDump

[Edit]
List the managed stack trace for running .NET processes

Download


StackDump has been an open source project and are now located at stackdump.codeplex.com
Download version 0.1

How does is work.


The application goes in with a managed debugger (mdbg – linked in so nothing has to be installed). The debugger stops the application and generates a list of all CLR stacks running for the process. The application is started again. This operation is a quick operation and can be executed on a running production server with unchanged production code.

Usage:


Copy the file to a folder and open a command prompt ant execute the command

stackdump <process id>

Example



stackdump 6780

Tested on


.Net 3.5
Windows 7 (x64), Windows 2008 (x64), Windows 2003(x86)

Not working


IIS7 running in 32 bits mode

Script to dump all stack each 10 second


Save it to a file (example stackdump10.cmd)
Execute it with the processid
Example:
StackDump10 1024
Remarks for version 0.1 of stackdump.exe:
This script will never terminate sense version 0.1 always returns 0 as exit code.

:noerror
ping -n 10 127.0.0.1 > NUL 2>&1
stackdump %1 > "StackDump_%DATE:/=%__@_%time:~0,2%%time:~3,2%%time:~6,2%%.txt"

if %ERRORLEVEL% EQU 0 goto :noerror


Version author:
Mattias Lövström

EPiServer version

All