3

We've got a problem with a web service that we think is causing the app pool to restart itself but we're not seeing a message in the event log. This raises the question of whether or not our hypothesis is correct. So two questions really...

  1. Should we be seeing a message of some sort in the event log related to IIS? Even a "Hey I started and everything is great!" because we're not. We see 0 messages related to IIS in our event logs.

  2. If we should be seeing a message what can we do to start seeing messages?

ShaneC
  • 221
  • 4
  • 9

1 Answers1

3

From my answer on StackOverflow

You might want to turn on full AppPool Recycle Event logs:

 cscript adsutil.vbs Set w3svc/AppPools/DefaultAppPool/LogEventOnRecycle 255

You also might want to take a look at this Scott Guthrie blog article: http://weblogs.asp.net/scottgu/archive/2005/12/14/433194.aspx that shows how to write code in Global.ASAX to log the actual cause of an Application.End event.

This has been extremely useful to us in diagnosing several screwy issues - one in partictual was an app that was writing log files to the wwwroot directory - too many file changes resulting in a recycle...

Christopher_G_Lewis
  • 3,685
  • 22
  • 27
  • Turning on those logs won't really make a difference since we can't see any logs in the event log or am I looking somewhere else for them? The Scott article sounds useful though.. – ShaneC Aug 14 '09 at 21:53
  • LogEventOnRecycle=255 will turn on full logging on AppPool Recycling. If this is set to 0, then you won't be getting any logging. – Christopher_G_Lewis Aug 15 '09 at 12:55
  • Made the change and we still get no logs... – ShaneC Aug 17 '09 at 13:57