I am trying to deploy an ASP.NET MVC 4 web application to a production server (Windows Server 2008 R2 [x64] with SP1 installed, running IIS 7.5) that already has several other w
The problem was with my publish settings. I was using the following precompile options in Visual Studio 2012:
By selecting 'do not merge' or 'merge all outputs to a single assembly', the problem was alleviated.
UPDATE:
The problem resumed even with the other settings, it just didn't happen right away. I had to disable precompiling altogether.
I want to give my 2 cents here. I had this exact behaviour on Windows Server 2012.
My problem had nothing with configuration but the fact the global.asax
was having an exception in the Application_Start
and my code to register the routing table never occurred after the recycle. So if you have this behaviour, make sure you trap exceptions and handle them so all your code execute.