Questions tagged [sos]

SOS is a debugger extension that allows a developer to inspect the managed state of a .NET Core and desktop runtime process. SOS can be loaded by WinDbg/cdb debuggers on Windows and lldb on Linux and macOS.

SOS (Son of Strike) is a debugger extension that allows a developer to inspect the managed state of a .NET Core and desktop runtime process. SOS can be loaded by WinDbg/cdb debuggers on Windows and lldb on Linux and macOS.

Useful links:

344 questions
4
votes
1 answer

Free ~90% Gen2 .NET heap

We are trying to debug the memory leak on our windows hosted service. I got the process dump and started analyzing in windbg. Heapstat showing that >~90% memory in SOH is free, but not getting garbage collected. System is throwing OutOfMemory…
4
votes
1 answer

!threads command showing XXX thread id

When I run the !threads command, in the left most columns for few threads i see id as XXX. My understanding is that this mean dead threads. Does this includes any threads that exited (gracefully or ungracefully) or is it for any threads that didn't…
imak
  • 6,489
  • 7
  • 50
  • 73
4
votes
1 answer

Cannot open Azure App Service .NET Core 2 dump file in WinDGB (2 runtimes present in dump file)

I'm having some troubles opening a dump file of a .NET Core process in WinDBG. I used to debug .NET framework dumps using WinDBG, without any issues, but with a dump coming from an Azure App Service there is something weird: both the clr.dll and the…
Jerome Thievent
  • 295
  • 2
  • 8
4
votes
1 answer

What do I do to run Windbg/dbeng.dll commands from within the Visual Studio debugger and the Immediate Window?

I saw in a video talk by Bart de Smet where he was running Windbg commands by typing them into the Immediate Window in Visual Studio when running the project in debug mode inside the Visual Studio debugger. So, I wanted to try that myself. So here's…
Water Cooler v2
  • 32,724
  • 54
  • 166
  • 336
4
votes
1 answer

What's the ip2md equivalent in ClrMD

I know how to iterate the object in the memory, but I'm about to do something with ClrMD as the !ip2md command in WinDBG/SOS. What exactly should I do?
Jeffrey Zhao
  • 4,923
  • 4
  • 30
  • 52
4
votes
2 answers

cpu time consumed by a process and its threads

I am trying to understand the math of CPU time consumed by various threads in an application. The .time command below tells me that my process is up for about 7 minutes which to my understanding is basically the CPU time this process has overall…
paul deter
  • 857
  • 2
  • 7
  • 20
4
votes
1 answer

Trying to find object roots using CLR MD

Here is my class namespace MyNamespace { public class MyClass { private byte[] imageBytes = null; public MyClass() { } public void LoadImage(string filePath) { Image img =…
paul deter
  • 857
  • 2
  • 7
  • 20
4
votes
2 answers

How to load SOS in Windbg for a 32bit app running on a 64bit server

Trying to debug a process dump of a 32-bit .NET application running on a 64-bit Windows edition Using debugger 6.3.9600.16384 x86. Spent a couple of hours searching for a solution. Found numerous topics on stackoverflow and other sites, however I'm…
RB84
  • 331
  • 4
  • 15
4
votes
1 answer

How to determine GC workstation vs server mode from dump file

From a dump file, is it possible to determine that Garbage collection mode used server vs workstation)? If so, what command?
crazy novice
  • 1,757
  • 3
  • 14
  • 36
4
votes
1 answer

OutOfMemoryException - is this a false alarm

My dump file contains OutOfMemoryException but all the object fields seem to be null. Is it just a false alarm or is there someway to know about this exception? 0:052> !do 000000027fff10e8 The version of SOS does not match the version of CLR you…
crazy novice
  • 1,757
  • 3
  • 14
  • 36
4
votes
2 answers

Windbg: psscor4 doesn't work

I searched and tried a lot of things, but can't get psscor4 to work properly. When I invoke !threads, I'm always getting Failed to request ThreadStore The things I checked are as follows: I'm having a .NET 4 application that's compiled for X86…
code-factory
  • 249
  • 1
  • 4
  • 11
4
votes
2 answers

Advanced .NET Debugging

I'm reading Advanced .NET Debugging book and I like it very much. However I have some problems with the examples. I would really appreciate if someone that has read it helped me. I have two questions: Versus what version of .NET framework are…
Piotr Perak
  • 10,718
  • 9
  • 49
  • 86
4
votes
1 answer

How do I use !gcroot

From within visual studio immediate window with SOS debugging extension loaded I can do !dumpheap -stat Then I get something like this: total 108,014 objects Statistics: MT Count TotalSize Class Name ... 0x00be209c 135 …
bitbonk
  • 48,890
  • 37
  • 186
  • 278
4
votes
3 answers

using sos to debug visual studio

I am trying to debug a visual studio 2010 addin using SOS. I attached windbg but there is no clr.dll. I tried .loadby sos mscoree, .loadby sos corjit, and none of them worked. I got kinda working by switching to x86 mode with !sw and copying sos…
user1985513
  • 481
  • 1
  • 4
  • 13
4
votes
1 answer

creating minidump of a 32bit process running in 64 bit OS

I have a .net app which is designed to run in a 32 bit environment and it runs in 64 bit OS in wow64 environment. Now i am creating an utility(32 bit) to create dump for the application. I use the following code to create a…
Rockstart
  • 2,337
  • 5
  • 30
  • 59