IIS 7 and Above
Application Initialization Module
Application initialization preload no longer works after deploying .N...
Last post Aug 04, 2012 01:34 AM by vijendra_cs
Jun 05, 2012 06:00 PM|pgbross|LINK
I have been experimenting with the recent application initialization (RC) for IIS 7.5. I tested on my local Windows 7 development system, and then deployed to my production Windows Server 2008 R2 machine and repeated my tests with a temporary app pool. I
was able to observe the application pool start immediately when the startMode="alwaysRunning", and when the site's preloadEnabled="true" attribute was configured, the site served my startup.htm file whilst the application was initializing.
Over the weekend I deployed the latest .Net 4.5 RC and upgrading both my developer workstation and, after verifying my applications still behave, my production server. Unfortunately, although my workstation can still warm-up sites, my server is now stubornly
refusing to warm-up the site. In all other respects the system is behaving as if the preloadEnabled attribute was not set, though I have checked in IIS configuration that the settings are still present correctly. On the first request from a browser to the
site after starting or recycling the app pool, I receive my startup.htm file, and then if I refresh after a few seconds I get the content from the site.
Is this a known conflict in some way between the .Net 4.5 RC on Windows Server 2008 R2 (even though my Windows 7 workstation
does work)? I have tried watching what happens when I turn on failed request tracing for all statuses 200-500, and there are no logs from the preload on recycling the app pool (they do turn up of course when a browser connects). Are there any other
logging options available either specifically for the application initialization extension, or IIS Extensions in general - perhaps a system.diagnostics trace flag or something?
Of course it could be a coincidence that installing .net 4.5 rc appears to have broken the warmup preload, but it is looking a bit suspicious and I am not aware of making any other changes that could account for it not working on the server any more. If
anyone has any information on whether this is a known issue, or if there are other reasons it might have stopped, I would be grateful for any help or thoughts you might have.
As a temporary workaround I have configured an arr server to have "Health Tests" that test the sites every 30 seconds so it warms the application that way and the design of the application means that is fairly low overhead. But I don't like hijacking the
health tests in this way as they are no for checking the health of an application, but should be a simpler test returning some response to indicate the
server is ok.
Jun 06, 2012 05:46 AM|pgbross|LINK
I have been experimenting since yesterday's Post and have managed to get a little more debugging information. I went through all the settings and double checked the tracing settings for the production server and noticed that tracing wasn't fully enabled
in the "Role Services" for the web server.
After changing that setting the Failed requests now get logged when preloadEnabled="true" is set and the app pool is recycled. The error logged is from "IIS Web Core" and the error code is 0x80070057 (the parameter is incorrect). Looking up that error it
appears to be most likely an ERROR_PIPE_BUSY status. After searching the web for that status I found one appfabric post that refers to the same error that concluded it was a bug in IIS caused by a timing issue between the World Wide Web Publishing service
and the IIS worker process.
I'm not sure if this is the same issue I am seeing or if the symptoms just happen to be similar.
Jun 08, 2012 11:42 PM|ahmels|LINK
Is the preload you are trying to make on a root site level or application level?
I mean is the preloadEnabled set on an app like this
<application path="/" applicationPool="Default Web Site" preloadEnabled="true">
or like this
<application path="/Application1" applicationPool="Default Web Site" preloadEnabled="true">
Jun 27, 2012 11:01 AM|pgbross|LINK
Sorry for the delay in replying, I somehow managed to miss your reply.
The preload I am making is on a root site level like
<application path="/" applicationPool="My Web Site" preloadEnabled="true">
Jul 30, 2012 05:40 AM|pgbross|LINK
I have have just upgraded to the released version of Application Initialization 1.0 for IIS 7.5 (7.1.1636.0) and the problem I was seeing with the RC has been resolved.
On starting an apppool configured for AlwaysRunning with an asp.net mvc 4 web application deployed at the site root I see a w3wp.exe process start
and a request to my initializationPage (currently configured to be "/"). Whilst initializing, the site serves my static startup.htm page correctly which is what was failing in the release candidate version. I have also tried recycling my apppool and
it also correctly handles the preloadEnabled=true site setting, warming up the new w3wp instance before terminating the previous instance (when disallowOverlappingRotation=false then I see the startup.htm page during the warmup phase).
Aug 04, 2012 01:34 AM|vijendra_cs|LINK
I tried using Application Initialization on both Win 2008 r2, iis7.5 and Win 7, iis 7. Its not working as expected. I downloaded the x64 version. (http://www.iis.net/download/ApplicationInitialization)
<add name="MyApp" autoStart="true" startMode="AlwaysRunning" managedRuntimeVersion="v4.0">
<site name="Default Web Site" id="1" serverAutoStart="true">
<application path="/MyApp" applicationPool="MyApp" preloadEnabled="true">.
Application web config file
<add initializationPage="/default.aspx" />
Its not having any effect. When I restart IIS and loaded the URL in browser
http://localhost/myapp/default.aspx it didnt showed the loading.html page, neither it looks like the appPool is always running\warmed up.
Also, it didnt showed the multiple instances of w3p process. Its not working.
A small video for configuring Application Initialization module on Win 7, IIS 7 or Win 2008 R2, IIS 7.5 would be helpful, because may be I have missed something.