views:

133

answers:

1

My webservice produces a "Service not available" error first, then when I restart the IIS service it works. When i checked the eventlog I found this error concerning ASP.NET 2.0.50727.0

Event code: 3005 Event message: An unhandled exception has occurred. Event time: 1/13/2010 5:31:02 PM Event time (UTC): 1/13/2010 10:31:02 PM Event ID: a3f163d4529d4e7389fd9828ef75a5f3 Event sequence: 2010 Event occurrence: 2 Event detail code: 0

Application information: Application domain: /LM/W3SVC/337954533/Root-1-129078638848593750 Trust level: Full Application Virtual Path: / Application Path: C:\Inetpub\wwwroot##\ Machine name: MU

Process information: Process ID: 6096 Process name: w3wp.exe Account name: NT AUTHORITY\NETWORK SERVICE

Exception information: Exception type: TargetInvocationException Exception message: Exception has been thrown by the target of an invocation.

Request information: Request URL: https://www.##.com:443/AccountList.aspx?type=RklYRUQgREVQT1NJVA1/13/2010 5:31:02 PMd1/13/2010 5:31:02 PMd-ch1BLi4bsZQ1/13/2010 5:31:02 PMd Request path: /AccountList.aspx User host address: ##.##.##.## User:
Is authenticated: False Authentication Type:
Thread account name: NT AUTHORITY\NETWORK SERVICE

Thread information: Thread ID: 7 Thread account name: NT AUTHORITY\NETWORK SERVICE Is impersonating: False Stack trace: at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at System.Web.UI.WebControls.ObjectDataSourceView.InvokeMethod(ObjectDataSourceMethod method, Boolean disposeInstance, Object& instance) at System.Web.UI.WebControls.ObjectDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) at System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) at System.Web.UI.WebControls.DataBoundControl.PerformSelect() at System.Web.UI.WebControls.BaseDataBoundControl.DataBind() at System.Web.UI.WebControls.GridView.DataBind() at System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() at System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() at System.Web.UI.Control.EnsureChildControls() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

+1  A: 

You might want to check the recycling/memory settings of your application pool. I've experienced similar errors that occur when memory objects grow too big and the app pool begins to choke. You may also want to download the IIS debug diagnostics tools:

http://support.microsoft.com/kb/919789

Joel Etherton
The thing is, none of the IIS services stopped as far as the system log is concerned.
D0cNet
The IIS service itself doesn't stop. What happens is an exception (somewhere) causes the w3wp.exe process to crash. This leaves the W3SVC intact but the application turns itself off. You can also try disabling "rapid fail protection" in the application pool properties to alleviate the symptom, but that will only mask the real problem.
Joel Etherton
I guess the best approach is to 1. configure recycling of the application pool once the worker process for my webservice gets large 2. Go through the code and make sure objects are being used and disposed properly.. any suggestions?
D0cNet
Too many to list here. A lot of things could be causing this. In my case it was a fairly large session object that had a memory leak (kept adding to itself with every page view). My immediate solution was to separate the session state from InProc to StateServer, but this only delayed the problem. The debug diagnostics was how I tracked down what was doing it. But be patient. It traps a LOT of info.
Joel Etherton