Monday, October 03, 2011

ASP.NET : Handler “PageHandlerFactory-Integrated” has a bad module “ManagedPipelineHandler” in its module list

 

I do a lot of work developing applications on my Windows 7 32 bit machine using IIS 7.5 and then migrating them to IIS 7.5 on my Windows Server 2008 R2 64 bit box. Not as simple as it sounds.

Using VS 2010, my DefaultAppPool on Windows 7 uses the .NET 4.0 framework whereas it’s 2.0 on Windows 2008. So you need to make a new application pool and set it to “Integrated” and the 4.0 framework.

OK – then I get the above error. The blurb below on the error page says that the most likely cause is that:

“Managed handler is used; however, ASP.NET is not installed or is not installed completely.”

Check my installed features in IIS 7.5 and Yup – ASP.NET is installed, it has a handler etc. So WTF?

Mr. Google to the rescue.

Run a command prompt in administrative mode.

C:\Windows\Microsoft.NET\Framework\v4.0.30319>aspnet_regiis.exe -i
Start installing ASP.NET (4.0.30319).
..................
Finished installing ASP.NET (4.0.30319).

Note: Your version of the framework may be different!

Notice that it installs ASP.NET even though it is already supposed to be there but it fixes the problem and all is well!

Enjoy!

No comments: