IIS 7, .Net 4.0 Beta 2 and 503 Service Unavailable…after Beta 1

After recently installing Visual Studio 2010 Beta 2 and creating a .Net 4.0 site, I tried to step out of Cassini and into IIS only to get “503 Service Unavailable” and a killed worker process. Checking the event viewer I found the following errors.

The worker process failed to initialize correctly and therefore could not be started.  The data is the error.

Followed by…

The worker process failed to pre-load .Net Runtime version v4.0.20506.

The Google was no help. It returned a handful of result that weren’t all that helpful, but one post was interesting. Someone had a similar problem with the  2.0 runtime when upgrading to the beta and found there were tiny bits of the other runtime sticking around.

I had .Net 4.0 Beta 1 installed before, so I did some digging and found I had the Beta framework:

C:\Windows\Microsoft.NET\Framework\v4.0.21006
C:\Windows\Microsoft.NET\Framework64\v4.0.21006

I also had folders from the Beta 1

C:\Windows\Microsoft.NET\Framework\v4.0.20506
C:\Windows\Microsoft.NET\Framework64\v4.0.20506

I deleted those folders, restarted the .Net 4.0 app pool’s and and hard restart just to be safe. Everything worked. Two hours on a Friday wasted, but we weekend free of worry.

9 Comments so far

  1. Lawrence Alan on November 5th, 2009

    I am having the same issue right now, I had Beta 1, now I’m using Beta 2…

    Did you just remove the two v4.0.20506 folders?

    Restarting now.

  2. mark on November 5th, 2009

    @Lawrence Yes. That’s all I did and it stated working.

  3. [...] Looks like mark @ fooberry.com had the same issue: [...]

  4. jonathan on November 21st, 2009

    Yep this worked for me,

    ive installed beta 2 and VS2010 and im creating an MVC app,

    spend ~4 hours trying to get this working

    thanks :)

  5. mark on November 24th, 2009

    @jonathan That’s about how long it took me as well…the pains of bleeding edge.

  6. Arni on December 14th, 2009

    Thanks! Your post probably saved me several hours :)

  7. mark on December 16th, 2009

    @Arni Glad to help.

  8. P on March 10th, 2010

    Thanks- saved me a bunch of time.

  9. jeff on June 6th, 2010

    thanks. Even though I hadn’t installed beta versions, I found a 0 byte file called V4.0.303 which was causing the same error.

Leave a Reply