windbg

!syncblk identify waiting threads

when I ssued !syncblk command on a deadlocked application from windbg, I got the following output. It shows which thread holds the lock. But it does not indicate which threads are waiting for the lock. How can I identify the threads that are waiting? . 0:004> !syncblk Index SyncBlock MonitorHeld Recursion Owning Thread Info SyncBlo...

windbg "Free" object type

Monitoring my program's Virtual Bytes usage while it is running showed that by doing some kind operations, the virtual bytes usage goes up by about 1GB in about 5 minutes. The program deals with tcp sockets and high data transfer throughput between them (~800Mbps). Loading a dump file of the program in windbg showed that the reason for ...

Windbg with xp embedded, ntdll.dll symbols fail, other symbols affected?

I am using windbg with xp embedded. Attempting to fetch the operating system symbols fails with the message "Symbol file could not be found. Defaulted to export symbols for ntdll.dll". (Is this typical for xp embedded???) I have no problem locating and loading symbols and source for my own code. However stepping through the code suggest...

problems in starting a script in WinDbg

hi all I am trying to run a WinDebug script but I cannot. The script I have is preatty simple and called DBG_SCRIPT.txt in the same folder where WinDbg is located. It has the following code that basically starts a debug session. .echo "hi I am starting debugging" g I tried the following command line but it doesn't start. windbg c:...

How to find the event handler for a DispatcherTimer in windbg

I have a Silverlight 3 application which seems to be leaking DispatcherTimer objects. At least, over time when the application runs I find more of them on the heap: !dumpheap -type DispatcherTimer returns an increating number of them. I'd like to find the Tick event handler method for these so I can identify where they're created in m...

WinDbg to debug System.IO.IOException

I have a full dump file from a custom exe crash. When i review the threads, i see System.IO.IOException and print exception gives me the below error. I suspect there is some sort of thread racing leading to this since we are on a vanilla Windows2008 (x64) server that doesn't have any virus scanners or indexing services installed. Any ide...

Get method name form delegate with WinDbg

Hello, I have the following dump of delegate object: Name: MyEventHandler MethodTable: 132648fc EEClass: 1319e2b4 Size: 32(0x20) bytes Fields: MT Field Offset Type VT Attr Value Name 790fd0f0 40000ff 4 System.Object 0 instance 014037a4 _target 7910ebc8 4000100 8 ......

windbg break on file open

I have a .net application which I don't have source too. I'm interested in determining what files this application is accessing. I thought that a debugger would be a good way to do this. I work only in the linux world and know nothing about windows debuggers. I feel like there should be a way to do this with windbg, I know how I woul...

only 3 functions are exported in the dbgeng.dll?

From some books, I knew that the dbgeng.dll is the debug engine for the debugger, it exports lots of methods for debugging. But with depends, I found that only 3 functions(as below) are exported in the dbgeng.dll, so how can those debuggers like windbg.exe/cdb.exe use the dbgeng.dll DebugConnect DebugConnectWide DebugCreate ...

Windbg with SOS, stopping on the correct exception

I have a windows service that is, intermittently, throwing an exception that sometimes kills its SQLConnection, and other times kills the service completely. It is running live on a customer's site. I have planned to use Windbg + SOS on it to get a crash dump, so that I can debug this at my own leisure. On my first attempt, however, th...

Windbg with SOS, How to dump a c# struct

How do I dump a struct using windbg, is there a dumpstruct command similar to dumpobject? Or can dumpobject dump structs aswell? ...

COM exception on "custom component" - how to identify DLL?

We have a large legacy VB app made up of a number of DLLs (a couple of dozen or so), all installed into a single COM+ Server Application. Every now and then, something happens that causes dllhost.exe to keel over (and automatically restart), leaving this message in the Windows Application Event log... The system has called a custom c...

Books about/for deeper understanding debugging C or C++ (assembly) on Windows?

I'm a professional C++ programmer and I'm pretty OK with the Visual Studio debugger (currently using 2005). I halfway know what a processor register is supposed to be, I can make something of a disassembly view (mostly guessing at what individual asm instructions might do). I know about symbol files -- that is their existence and how to ...

How to get SLC.pdb to analyze memory dump

I am using windbg 6.12.0002.633 X86 on Windows Vista to analyze memory dumps for memory leaks. I'm trying to use the command `dumpheap -stat to determine the quantities of objects in the heap. Unfortunately, I'm getting the error *** ERROR: Symbol file could not be found. Defaulted to export symbols for SLC.dll. I have activated !sym no...

Can I install both x86/x64 windbg on my x64 WIN7?

I need to analysis some x86 dump file, So I want to install the x86 windbg on my computer. or if I can use the x64 windbg to analysis the x86 dump file? ...

Value type vs Reference types via WinDbg

I am new to Windbg and trying to understand a few things about value and refernece types .NET. Here is the code that i am using class Program { struct MyStruct { int x; int y; } class MyClass { int x; int y; } static void Main(string[] args) { MyStruct s ; ...

!ClrStack local variables - is it value type or reference type

How can I determine if the local variable is a value type or a reference type? 0:000> !CLRStack -a OS Thread Id: 0xf74 (0) Child-SP RetAddr Call Site 000000000023e9c0 000007fef6b32012 ConsoleApplication2.Program.Main(System.String[]) PARAMETERS: args = 0x00000000028f3c70 LOCALS: 0x000000000023e...

understanding DumpStackObjects

I have a small test program. When I look into stack object for main thread, its showing MyClass twice there. Any ideas why there are two object of MyClass on the stack? class Program { struct MyStruct { int x; int y; } class MyClass { int x; int y; } ...

Understanding CLR object size between 32 bit vs 64 bit

I am trying to understand the object size difference between 32 bit and 64 bit processors. Let’s say I have a simple class class MyClass { int x; int y; } So on a 32 bit machine, an integer is 4 bytes. If I add the Syncblock into it ( another 4 bytes), the object size will be 12 bytes. Why is it showing 16 bytes? ...

IIS Hanging. Bizarre Callstack: Unknown MethodDesc

Hi, I am having general hangs on our IIS application pool. Sometimes, when I get a Crash Dump, I get one thread which is blocking all the others and that has no call stack: ESP EIP 4735e1dc 7c82860c [NDirectMethodFrameStandalone: 4735e1dc] Unknown MethodDesc (Module 1f3363e8, mdToken 0600016c) I looked over the Internet bu...