2

I am using the IIS Advanced Logging module on a production server running IIS 7.5.

I need to change some of the settings (specifically, which fields are logged) and cannot find anywhere that indicates whether or not this will cause an AppPool recycle or an App restart. Since it is a production system, I need to avoid this.

Thanks in advance.

4

Changing the fields to be logged will not cause the AppPool to recycle but it will kill the current AppDomain and start a new one on the next request. So any session state (if in process) is lost.

You can easily test this:

 <%@ Page language="c#" %>
 <html>
    <% if (Session["starttime"] == null) { Session.Add("starttime", DateTime.Now.ToString()); }; %>
    <%= Session["starttime"] %>
 </html>

load the page twice to see the time, then change your log settings and reload the page, you'll get a new time.

| improve this answer | |
  • Thanks for the help, Peter. So, if I'm understanding you correctly, a restart of the AppDomain will still cause the ASP.Net web site to restart... including JIT compilations of .cshtml pages etc? When this happens the first request to the site usually takes ~30 seconds... – Leland Richardson Feb 26 '14 at 20:11
  • I haven't checked about JIT compilation. I would test this with your app in a separate AppPool or a different server, just to be sure what exactly happens in your case. – Peter Hahndorf Feb 26 '14 at 20:15
  • 1
    For anyone wondering, I checked this, and it does indeed restart the application. Thanks. – Leland Richardson Feb 27 '14 at 21:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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