Monday, June 11, 2012

Problems installing ASP.NET MVC3

I recently installed the CMS Umbraco 5, but I had problems getting it to run because I didn't have MVC3 installed. When I used Web Platform Installer to install it - it didn't work (I think there was no error message even) - after installing MVC3 the files where nowhere to be found.

The error you'll receive is (when running Umbraco): Could not load file or assembly 'System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

The reason MVC3 won't install is because I had a newer version of NuGet installed (v1.5). The installer produces a fatal error when it finds a newer (than 1.2) version instead of continuing. The semi-official fix from Microsoft is to uninstall Nuget, install MVC then reinstall Nuget.

There is also another workaround, to manually run the installation files after the installer has extracted them (start installation, when it fails find the extracted installation files in the Temp folder and copy them somewhere else. Then install them manually after finishing the first install).

Note that the problem is actually in the 'MVC3 Tools' package, so for me it worked to simply install the binaries (since I'm just going to run Umbraco, not develop MVC3 apps I don't need the tools).

Download just the runtime from here: http://www.microsoft.com/en-us/download/details.aspx?id=4211

The tools are here (in case you need them): http://www.microsoft.com/en-us/download/details.aspx?id=1491

No comments:

Post a Comment