Application Pool Recycles from IIS 7 Setting Changes

I've written a couple times about what configuration changes cause AppDomain recycles.  Most recently how the ASP.NET tab causes a server-wide AppDomain recycle, and previously about changes in ASP.NET 2.0.

Here I'm going to cover things that, when done in IIS 7, will cause a full application pool recycle.  I obtained the following list from the Microsoft.com folk at Microsoft.  They worked with the IIS team during IIS 7 development to get a complete list of all settings which cause full app pool recycles.  What this means is that if you make changes to applicationHost.config that touches anything in the following list, the applicable application pool will be recycled.  If you change other settings to applicationHost.config, the app pools on the server will remain unaffected.

Note: It's important to realize that an application pool in IIS is different than an AppDomain in ASP.NET.  The previous blog posts were about AppDomain recycles, but this one is about application pool recycles. 

Windows Activation Process Service (WAS) recycles an application pool if you change the configuration of any of the following:

  • Restart parameters (for example, restart time, number of requests, and scheduled memory)
  • Idle timeout
  • Ping interval
  • Startup and shutdown time limit
  • Orphan action
  • CLR version
  • Pipeline mode
  • A 32 to 64 bit worker process
  • Job objects (for example, CPU limit)
  • CPU affinity
  • Worker process identity

Essentially this means that virtually any change to the application pool settings will cause it to immediately recycle, so be careful when making a change to an app pool.  This applies when using IIS Manager, any of the programming APIs or if you edit applicationHost.config directly.  You may need to schedule to setting change off hours if you don't want a recycle to occur at an inopportune time.  Changes to global settings will not cause the application pools on the server to recycle.

Note: This isn't significantly different than IIS 6.  In IIS 6, app pool changes will cause a recycle as well.  This is just a fresh look at IIS 7 recycles.

2 Comments

Comments have been disabled for this content.