I am starting up Windbg and trying to load SOS and I get the error:
0:000> .loadby sos.dll mscorwks
The call to LoadLibrary(C:\Program Files\Debugging Tools for Windows
(x86)\sym\mscorwks.dll\4BEBD49A591000\sos.dll) failed, Win32 error 0n126
“The specified module could not be found.”
Please check your debugger configuration and/or network access.
If I preface the call with
.symfix
.reload
.loadby sos.dll mscorwks
I simply get the warning:
sos.dll needs a full memory dump for complete functionality.
You can create one with .dump /ma
I am not sure what I need to do so that mscorwks starts up without first having to use the commands .symfix and .reload?
One more question. I copied the sosex.dll to the installation directory of Debugging Tools for Windows (x86) and I get:
0:000> .load sosex.dll The call to LoadLibrary(sosex.dll) failed, Win32 error 0n193 “%1 is not a valid Win32 application.” Please check your debugger configuration and/or network access.
This may have to do with the fact that the sosex.dll assembly is x64. I am not aware of where x64 for Debugging Tools for Windows is available so I was assuming that the x86 version will support bot via something like WOW64?
Are you sure that this is not an .NET 4.0 Process? ‘mscorwrk.dll’ don’t exist anymore. The unmanaged CLR Implementation is now in ‘clr.dll’.
You shall use:
.loadby sos clr
You can first check with
lm
if the ‘clr.dll’ module is loaded.
For .NET 4.0 Debugging you have to use a recent version of windbg (6.12 works for sure, 6.9 not).
Are you attaching to a running process, or starting a new one? If it’s a new process the CLR will not be loaded at the initial Breakpoint. You can eigher use
.load or wait until you get the Load-Image notification for clr.dll.
It is not a .NET 4.0 process (at least I don’t think it is). I compiled with
VS 2010 but in the project settings I indicated .NET 3.5. So I am pretty
sure that it isn’t. I will check with ‘lm’ just to be sure. Thank you.
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@world-direct.at
Sent: Thursday, February 17, 2011 4:07 AM
To: Kernel Debugging Interest List
Subject: RE:[windbg] Loading SOS
Are you sure that this is not an .NET 4.0 Process? ‘mscorwrk.dll’ don’t
exist anymore. The unmanaged CLR Implementation is now in ‘clr.dll’.
You shall use:
.loadby sos clr
You can first check with
lm
if the ‘clr.dll’ module is loaded.
For .NET 4.0 Debugging you have to use a recent version of windbg (6.12
works for sure, 6.9 not).
Are you attaching to a running process, or starting a new one? If it’s a new
process the CLR will not be loaded at the initial Breakpoint. You can eigher
use .load or wait until you get the Load-Image notification for clr.dll.
The Path ‘C:\Program Files\Debugging Tools for Windows
(x86)\sym\mscorwks.dll\4BEBD49A591000\sos.dll’ seems to be strage. Are you debugging the Debugger?
The output of ‘lm’ would be very interesting in this case.
You have not answered if you are attaching to a proces or if you are starting a new one.
On Fri, Feb 18, 2011 at 6:11 AM, xxxxx@world-direct.at
wrote:
The Path ‘C:\Program Files\Debugging Tools for Windows
(x86)\sym\mscorwks.dll\4BEBD49A591000\sos.dll’ seems to be strage. Are
you debugging the Debugger?
The output of ‘lm’ would be very interesting in this case.
You have not answered if you are attaching to a proces or if you are
starting a new one.