I am monitoring my site with a healthMonitoring section. I see a message...
Event code: 1002
Event message: Application is shutting down. Reason: Hosting environment is shutting down.
Event time: 8/8/2011 3:29:59 PM
Event time (UTC): 8/8/2011 8:29:59 PM
Event ID: 6879adf29cdc403ba8ad2e5694b6cee0
Event sequence: 730
Event occurrence: 1
Event detail code: 50002
I am having trouble determining why it is getting shut down. My app pool is set to reset every 24 hours. My web.config sessions are set to expire after 4 hours (which shouldn't affect app shutdown anyway). I saw some posts mention that healthMonitoring settings can reset an application, but I don't see any specific setting there that would do that. Also, I noticed this problem before I added the healthMonitoring section.
Just for reference, here is how it reads...
<healthMonitoring>
<bufferModes>
<add name="Critical Notification" maxBufferSize="100" maxFlushSize="20"
urgentFlushThreshold="1" regularFlushInterval="Infinite" urgentFlushInterval="00:01:00"
maxBufferThreads="1" />
<add name="Notification" maxBufferSize="300" maxFlushSize="20"
urgentFlushThreshold="1" regularFlushInterval="Infinite" urgentFlushInterval="00:01:00"
maxBufferThreads="1" />
<add name="Analysis" maxBufferSize="1000" maxFlushSize="100"
urgentFlushThreshold="100" regularFlushInterval="00:05:00"
urgentFlushInterval="00:01:00" maxBufferThreads="1" />
<add name="Logging" maxBufferSize="1000" maxFlushSize="200" urgentFlushThreshold="800"
regularFlushInterval="00:30:00" urgentFlushInterval="00:05:00"
maxBufferThreads="1" />
</bufferModes>
<providers>
<add name="EventLogProvider" type="System.Web.Management.EventLogWebEventProvider,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a" />
<add connectionStringName="LocalSqlServer" maxEventDetailsLength="1073741823"
buffer="false" bufferMode="Notification" name="SqlWebEventProvider"
type="System.Web.Management.SqlWebEventProvider,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a" />
<add name="WmiWebEventProvider" type="System.Web.Management.WmiWebEventProvider,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a" />
</providers>
<profiles>
<add name="Default" minInstances="1" maxLimit="Infinite" minInterval="00:01:00"
custom="" />
<add name="Critical" minInstances="1" maxLimit="Infinite" minInterval="00:00:00"
custom="" />
</profiles>
<rules>
<add name="All Errors Default" eventName="All Errors" provider="EventLogProvider"
profile="Default" minInstances="1" maxLimit="Infinite" minInterval="00:01:00"
custom="" />
<add name="Failure Audits Default" eventName="Failure Audits"
provider="EventLogProvider" profile="Default" minInstances="1"
maxLimit="Infinite" minInterval="00:01:00" custom="" />
<add name="Application Lifetime Events Default"
eventName="Application Lifetime Events"
provider="EventLogProvider"
profile="Default"
minInstances="1"
maxLimit="Infinite"
minInterval="00:01:00"
custom="" />
</rules>
<eventMappings>
<add name="All Events" type="System.Web.Management.WebBaseEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Heartbeats" type="System.Web.Management.WebHeartbeatEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Application Lifetime Events" type="System.Web.Management.WebApplicationLifetimeEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Request Processing Events" type="System.Web.Management.WebRequestEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="All Errors" type="System.Web.Management.WebBaseErrorEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Infrastructure Errors" type="System.Web.Management.WebErrorEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Request Processing Errors" type="System.Web.Management.WebRequestErrorEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="All Audits" type="System.Web.Management.WebAuditEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Failure Audits" type="System.Web.Management.WebFailureAuditEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
<add name="Success Audits" type="System.Web.Management.WebSuccessAuditEvent,System.Web,Version=4.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"
startEventCode="0" endEventCode="2147483647" />
</eventMappings>
</healthMonitoring>
What could be causing my application to reset?
Thanks!
IIS can reset/restart for many reasons. From Tess Ferrandez's blog:
IIS will shutdown your application if it is idle (the default is 20 minutes of no activity), has consumed too much memory or CPU time.
Also anti-virus programs running on the web server have been blamed for resetting IIS, I assume by touching any of the files/directories that are mentioned above.
I was going over the same issues, and I started looking in other server logs to see if something else happened at the exact time of the recycle.
in the System event logs I found this:
A worker process with process id of '6600' serving application pool 'Version 1.2' has requested a recycle because the worker process reached its allowed processing time limit.
the source was: WAS
(Windows Process Activation Service)
I know that the reasons could vary, but for future references, one should look at other logs as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With