ASP.NET MVC 3 Deployment 403 Error on Windows Server 2008 R2 -


i'm deploying mvc3 application new server. application runs fine on development server (visual studio) , under iis7 on development machine, on server 403 error:

enter image description here

i have completed following steps, out of ideas. please help!

  • using same xcopy deployment technique used on development machine, have deployed files to server , added following permissions folder:

iusr - read & execute, list folder contents, read iis_iusrs - read & execute, list folder contents, read

  • i have installed asp.net mvc3 on server additional required .dlls in gac

  • iis set , can access basic html files (such test.html have dropped in @ site route).

  • i have checked in server manager role services installed

  • have attempted bin deploy copying files mvc install location , putting in bin directory

c:\program files (x86)\microsoft asp.net\asp.net mvc 3\assemblies

c:\program files (x86)\microsoft asp.net\asp.net web pages\v1.0\assemblies

ok, found problem. here incase else has same issue:

the server i'm using must have had .net 4 installed before iis. meant .net 4 hadn't been registered iis.

i noticed issue when checking iis config. clicking .net compilation icon website threw exception, presumably because application not compiled.

this led me stack overflow post directed me hanselman.com

in short, had install vs2010 on server had visual studio command prompt available, , register .net 4 iis on command line.

iis manager can't configure .net compilation on .net 4 applications

http://www.hanselman.com/blog/aspnet4breakingchangesandstufftobeawareof.aspx

key section:

"i installed asp.net 4 , installed iis."

if install vs2010 and/or .net 4 first, later install iis, need make sure iis configured know asp.net 4 otherwise iis have no idea how run asp.net 4 applications.

there's simple workaround

if in state, drop command line , navigate fx install directory. run "aspnet_regiis –iru".

note if on 64-bit machine, run command 64-bit fx install directory – not 32-bit installation directory.

or future reference, try enable iis , asp.net extensibility option first when building machines or vms. way when vs 2010 or .net subsequently installed, installation automatically detect presence of iis , auto-register it.


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

java - Output of Eclipse is rubbish -

jquery - Confused with JSON data and normal data in Django ajax request -