This is how I got my ASP.NET 5 MVC site to run on IIS 8.5. I had some initial problems and most information I found on internet was about earlier beta versions of the framework. All of these had lots of steps and and none of them helped me.
- Windows Server 2012 R2 (fresh install)
- IIS 8.5
- DNX Version: dnx-clr-x18.104.22.168-rc1-update1
- Visual Studio 2015 Update 1
- Added Server Role: Web Server (IIS).
And also ASP.NET 4.5 (under Web Server (IIS) -> Web Server -> Application Development).
This will also include the feature ASP.NET from .NET Framework and ISAPI Extensions, ISAPI Filters and also .NET Extensibility 4.5.
- Installed the HttpPlatformHandler 1.2 from:
- Compiled and Published the Web project in Visual Studio to a local folder.
Configuration: Release – x64 (will probably work with Any CPU also).
Target DNX Version: dnx-clr-x22.214.171.124-rc1-update1
- Copied the published output to the Web Server.
- Added a new Site pointing to the wwwroot in the published folder.
And that was all that was necessary. Obviously running an ASP.NET 5 site is much easier now when the release candidate is out.
After installing Update 10586.3 from Windows Update the Compact Framework projects could not be loaded in Visual Studio 2008. The error was something like “C:\Windows\Microsoft.NET\Framework\v3.5\Microsoft.CompactFramework.CSharp.targets’ cannot be found.”
I haven’t found any explanation of why this file (and some other Compact Framework files was removed during the update.
But the simple solution was to do a Repair/Reinstall of Visual Studio 2008.
Update August 17, 2016
Now Windows updated to Version 1607 (Build 14393.51) and the same problem is back again. It looks like we will have to do a reinstall of Visual Studio 2008 after each update of Windows 10.
Publishig a new project created with Visual Studio 2013 Update 3 and ASP.NET MVC4 on IIS 8.5 and Windows Server 2012 R2 only resulted in Error 403.14.
Since it was the first MVC project on that server I thought is was a configuration issue in IIS. After testing almost all suggestions found on Internet (most of the referring to IIS 7.5), I found someone with that same problem and had a solution.
The problem was the setting “Precompile during publish” when publishing. I publish to a local folder before sending it to the server and I’d selected that because I thought it would make the site faster. But this completely broke the site!
Disabling “Precompile during publish”, republishing it (locally) and sending it to the server and now it worked as expected!
If you try to connect to the ASP.NET Development Server included in Visual Studio from another computer, you simply just can’t.
It’s a safety feature from the Visual Studio team, but also a big headache for many developers. If you want to test a PDA connecting to a web service on ASP.NET Development Server it is not even possible to run the test software locally on the same computer as the server.
After searching the web I found this question (and solution) on stackoverflow: http://stackoverflow.com/questions/1730280/accessing-asp-net-development-server-from-another-pc-on-the-network.
But since the answer on stackoverflow is linking to download.com, downloading the SPI Port Forward program is another headache. After the download the file is well hidden in some temp folder far away. So I added a download here.
Download SPI Port Forward here
After starting the program. You enter the port number you want to remote connect to your local ASP.NET Development Server with in Local port. Enter localhost as Remote host. And enter the port that the ASP.NET Development Server is using as Remote port. Then Activate to enable the port forward.
Now you can connect to your local ASP.NET Development Server by connecting to: 192.168.1.15:12345. Where 192.168.1.15 is your local computer (with server) IP. And 12345 is the port you entered in Local port.
Developing WCF client for the Compact Framework needs the svcutil.exe (called NetCFSvcUtil.exe for devices) to generate the client.
Here is a post from MSDN Blogs about the program not working with Windows 7: NetCFSvcUtil.exe and Windows 7
And here you can download an updated version of the program: NetCFSvcUtil.exe