2

We are trying to maximize availability on our content delivery virtual machines. By default, IIS is set to recycle app pools every 29 hours.

app pool recycle Regular Time Interval in minutes setting

This value can be set to 0 such that IIS never recycles the app pool automatically. This seems like an easy win and it's specifically recommended in the book Sitecore Cookbook for Developers, but are there any reasons we might not want to do this? Are there any reasons why regularly scheduled app pool recycles might be desirable for a Sitecore site?

For example, while this is not Sitecore specific, this Microsoft blog post says:

You may ask whether a fixed recycle is even needed. A daily recycle is just a band-aid to freshen IIS in case there is a slight memory leak or anything else that slowly creeps into the worker process. In theory you don’t need a daily recycle unless you have a known problem. I used to recommend that you turn it off completely if you don’t need it. However, I’m leaning more today towards setting it to recycle once per day at an off-peak time as a proactive measure.

1 Answer 1

3

I did some investigation long time ago about that topic. I needed that for Dedicated Email Delivery servers, which were causing issues it EXM if their app pool was recycles during EXM campaign.

The only concrete arguments supporting the need of automated recycle of application pools were:

  1. To clear memory if there are any memory leaks
  2. In case there is "anything else that slowly creeps into the worker process"

I got unofficial recommendation from Sitecore to disable automated recycling of app pools. Why was it unofficial? My guess is that they didn't want to take any responsibility is something unexpected happens when app pools are not recycled regularly.

And that in fact is my recommendation for you. Disable and monitor. If you don't have any issues for the first week or month, it's very unlikely that you will have any issues later. Unless you add some code with memory leaks. But in fact, maybe it would be better to learn about it asap and act immediately, than use automated app pool recycling as a band aid.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.