all groups > dotnet clr > june 2006 >
You're in the

dotnet clr

group:

SOS.dll loses symbol information


SOS.dll loses symbol information JR
6/28/2006 3:25:17 PM
dotnet clr:
I originally posted this in the windbg forum but the folks suggested it
was more SOS than windbg so i should post over here.

I attach to the aspnet_wp process to debug a v1.1.4322 asp.net app. I
load the sos.dll and set my breakpoint inside a managed function call
via 'bp' command.
When it breaks i dump the stack and it looks great, Param names, source

line numbers and all. When i navigate to other sections of the site and

then return to hit the breakpoint again, all symbol information is
gone.

So i go from this ->
---------------------------


0x0086f714 0x05a99778 [DEFAULT] [hasThis] Void CEC.Staff..ctor(I4,I4)
at [+0x0] [+0x0] C:\All_prod_Source\CEC_MC\CEC\Staff.vb:329
PARAM: this: 0x012d5514 (CEC.Staff)
PARAM: int32 StaffID: 3228
PARAM: int32 CampusID: 0
0x0086f71c 0x05a99639 [DEFAULT] Class CEC.Staff
CEC.Academics.EnrollmentClass.GetAcademicAdvisor(I4)
at [+0x169] [+0x7b]
PARAM: int32 adEnrollID: 91591
0x0086f76c 0x05a98a34 [DEFAULT] [hasThis] Void
VC._default.AddStudentAcademicAdvisor()
at [+0x324] [+0x13f] C:\All_prod_Source\VC_MC\default.aspx.vb:244
PARAM: this: 0x012875e4 (ASP.default_aspx)
0x0086f838 0x05a9826e [DEFAULT] [hasThis] Void
VC._default.Page_Load(Object,Class System.EventArgs)
at [+0x66] [+0x12] C:\All_prod_Source\VC_MC\default.aspx.vb:87
PARAM: this: 0x012875e4 (ASP.default_aspx)
PARAM: class System.Object sender: 0x012875e4 (ASP.default_aspx)
PARAM: class System.EventArgs e: 0x00ed02f4


to this->
------------ :-(


to this 0x0086f714 0x05a99778 [DEFAULT] [hasThis] Void
CEC.Staff..ctor(I4,I4)
0x0086f71c 0x05a99639 [DEFAULT] Class CEC.Staff
CEC.Academics.EnrollmentClass.GetAcademicAdvisor(I4)
0x0086f76c 0x05a9888e [DEFAULT] [hasThis] Void
VC._default.AddStudentAcademicAdvisor()
0x0086f838 0x05a9826e [DEFAULT] [hasThis] Void
VC._default.Page_Load(Object,Class System.EventArgs)


Can anyone help me understand why SOS.dll loses the symbol info?
as always, thanks in advance for any and all help.
Re: SOS.dll loses symbol information JR
6/28/2006 4:57:56 PM
Yes, all webconfigs have debug=3Dtrue and the dlls are built as debug.
The info im talking about is actually pulled from the pdb files (souce
code file and line # ect). I have multiple apps on the site that use
the same dlls in the local bin. I think when i jump from one to another
and then come back it confuses it somehow.



[quoted text, click to view]
RE: SOS.dll loses symbol information DanNemesek NO[at]SPAM online.microsoft.com
6/28/2006 11:04:45 PM
Hi,

Are your pages set to debug=true?
Are your assemblies that you are calling from the page set to debug build?

Just a guess here but perhaps the first time you hit the page due to JIT
compilation SOS can better resolve symbols, but every subsequent hit it
can't.
From my experience without the debug settings = true you shouldn't get any
symbolic info for managed stuff.

Thanks,

Dan

This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. © 2002 Microsoft Corporation.
All rights reserved.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
Please reply to the newsgroups only.
Re: SOS.dll loses symbol information JR
6/29/2006 3:20:55 PM
Thank you for your reply.
Ok, here we go from the start

Start windbg
Attach to the aspnet_wp process (loads all modules)

At the command line I type ".load clr10\sos.dll"

Then "!sym noisy"
noisy mode - symbol prompts on

then ".reload"
Reloading current modules
..=2E.......................................................................=
..=2E.......................................................................
DBGHELP: ntdll - public symbols

c:\symbols\ntdll.pdb\36515FB5D04345E491F672FA2E2878C02\ntdll.pdb

then "k"
ChildEBP RetAddr
05a6ffc8 7c9507a8 ntdll!DbgBreakPoint
05a6fff4 00000000 ntdll!DbgUiRemoteBreakin+0x2d


Now I set a breakpoint for CLR exceptions. The bp will dump the managed
stack and then continue.
"sxe -c "!cen;!clrstack -p;g" CLR"

Then I hit go and load the main page. The debugger outputs the managed
stack along with the param names and actual source code line numbers.

System.InvalidCastException (0x15bba80)
Thread 1
ESP EIP
0x0086f6f4 0x7c81eb33 [FRAME: HelperMethodFrame]
0x0086f720 0x04effa67 [DEFAULT] ValueClass System.DateTime
Microsoft.VisualBasic.CompilerServices.DateType.FromObject(Object)
0x0086f760 0x04eff92f [DEFAULT] ValueClass System.DateTime
CEC.Data.DBConvert.CvDate(Object)
at [+0x4f] [+0x1b]
PARAM: class System.Object obj: 0x00e7b8e0 (System.DBNull)
0x0086f7b0 0x0496c409 [DEFAULT] [hasThis] Void CEC.VC.User..ctor(I4)
at [+0x4b1] [+0x277]
PARAM: this: 0x015b7c10 (CEC.VC.User)
PARAM: int32 UserID: 3064790
0x0086f880 0x05866781 [DEFAULT] [hasThis] Void
VC.BreadCrumb.Page_Load(Object,Class System.EventArgs)
at [+0xa1] [+0x52]
C:\All_prod_Source\VC_MC\Controls\Components\BreadCrumb.ascx.vb:25
PARAM: this: 0x0151fa60 (ASP.BreadCrumb_ascx)
PARAM: class System.Object sender: 0x0151fa60 (ASP.BreadCrumb_ascx)
PARAM: class System.EventArgs e: 0x00ed0558
0x0086f8d4 0x00b2b55b [FRAME: MulticastFrame] [DEFAULT] [hasThis] Void
System.EventHandler.Invoke(Object,Class System.EventArgs)
0x0086f8e8 0x056437dc [DEFAULT] [hasThis] Void
System.Web.UI.Control.OnLoad(Class System.EventArgs)

Now this works again and again if I refresh the page. When I click on a
different link that brings me to another section of the site I get the
same invalid cast exception dump but without the lines and param names.

System.InvalidCastException (0x12ae12c)
Thread 1
ESP EIP
0x0086f584 0x7c81eb33 [FRAME: HelperMethodFrame]
0x0086f5b0 0x04effa67 [DEFAULT] ValueClass System.DateTime
Microsoft.VisualBasic.CompilerServices.DateType.FromObject(Object)
0x0086f5f0 0x04eff92f [DEFAULT] ValueClass System.DateTime
CEC.Data.DBConvert.CvDate(Object)
0x0086f640 0x091e8611 [DEFAULT] [hasThis] Void CEC.VC.User..ctor(I4)
0x0086f710 0x091e7b6f [DEFAULT] Void
CEC.VC.UserCache.CacheUserInfo(I4,SZArray String,Class
System.Web.SessionState.HttpSessionState)
0x0086f7b0 0x091e6fb8 [DEFAULT] [hasThis] Void
VC.Navigation.Page_Load(Object,Class System.EventArgs)
0x0086f8d4 0x00b2b55b [FRAME: MulticastFrame] [DEFAULT] [hasThis] Void
System.EventHandler.Invoke(Object,Class System.EventArgs)

..reload

Reloading current modules
..=2E.......................................................................=
..=2E.......................................................................
DBGHELP: ntdll - public symbols

c:\symbols\ntdll.pdb\36515FB5D04345E491F672FA2E2878C02\ntdll.pdb

k

ChildEBP RetAddr
07f9ffc8 7c9507a8 ntdll!DbgBreakPoint
07f9fff4 00000000 ntdll!DbgUiRemoteBreakin+0x2d

The output from those commands looks exactly the same. I'm at a loss as
to why it cannot use the symbol information.



[quoted text, click to view]
Re: SOS.dll loses symbol information JR
6/29/2006 4:48:11 PM
Yes, different app domains with local DLLS in the bin of each app dir.
The dlls are the exact same though, symbols and all. I will keep
looking at it and try to give you more info.



[quoted text, click to view]
Re: SOS.dll loses symbol information DanNemesek NO[at]SPAM online.microsoft.com
6/29/2006 7:16:58 PM
Hi,

Execute the following commands to get the debugger to tell you what it's
doing during resolution
"!sym noisy"

Then execute ".reload" to get the debugger to re-resolve symbols using the
current sym path. Execute a "k" command to resolve a stack that contains
the image your interested so you can see what it does. If your image is not
in a current stack you can force it to load by executing ".reload /f
myimage.ext"

Do this when the symbols resolve and then repeat when the symbols don't
resolve to see if you notice any difference.

Thanks,

Dan

This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. © 2002 Microsoft Corporation.
All rights reserved.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
Please reply to the newsgroups only.
Re: SOS.dll loses symbol information DanNemesek NO[at]SPAM online.microsoft.com
6/29/2006 10:50:33 PM
Justin,

I will see if I can repro. I will keep you posted as to what the results
are.

Thanks,

Dan

This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. © 2002 Microsoft Corporation.
All rights reserved.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
Please reply to the newsgroups only.
Re: SOS.dll loses symbol information DanNemesek NO[at]SPAM online.microsoft.com
6/29/2006 11:12:51 PM
I wasn't able to repro using a simple two page test. See if you can repro
this using a simple two page test. If you can't give me more specifics on
your web app deployment, for example are you browsing through pages that
would be in different app domains?

Thanks,

Dan

This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. © 2002 Microsoft Corporation.
All rights reserved.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
Please reply to the newsgroups only.
AddThis Social Bookmark Button