?
Solved

MVC5 App runs on development machine but gives HTTP 404.0 or 403.14 when deployed to http://w.x.y.z/Default Web Site/Application

Posted on 2016-09-12
4
Medium Priority
?
117 Views
Last Modified: 2016-09-18
The MVS application CCCFE07 starts without problems on the development machine
It is deployed to our demo webserver using the Framework 4.5 Web-Deployment feature
server: http://80.90.100.110
site name: Default Web Site/CCCFE07
destination URL: http://80.90.100.110
Validate Connection is ok

RouteConfig is
namespace CCCFE07 {
    public class RouteConfig {
        public static void RegisterRoutes( RouteCollection routes ) {
            routes.IgnoreRoute( "{resource}.axd/{*pathInfo}" );

            routes.MapRoute(
                name: "Default",
                url: "{controller}/{action}/{id}",
                defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
            );
        }
    }
}
CCCFE07\Views\Home\Index.cshtml  exists

The Web Deploy feature installs the app on the server to Default Web Site/CCCFE07 and maps Default Web Site/CCCFE07 to the physical path c:\inetpub\wwwroot\CCCFE07 where we can see the subdirectories bin, Content, fonts, Scripts, Views

Trying to start the app on the server with
- localhost/cccfe07 gives error 403.14 Forbidden
- localhost/cccfe07/Home gives error 404.0 not found which seems reasonable since physical path C:\inetpub\wwwroot\CCCFE07\Home\ does not exist
- localhost/cccfe07/Views gives error: Method not found: '!!0[] System.Array.Empty
- localhost/cccfe07/Views/Home gives same error

"Enable Directory Browsing" is probably no option, since the configured start document shall be started
A default document is defined in RouteConfig (see above)

What must be done so that the http://localhost/CCCFE07 app can be startet on the Web Server?

Thanks for your help.

Joachim
0
Comment
Question by:joachim58
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 28

Accepted Solution

by:
Dan McFadden earned 2000 total points
ID: 41795549
1. Have you verified that the required .NET Framework is properly registered in IIS for the app?

I would read thru some of the following article, most are dealing with similar issues:

1. https://devio.wordpress.com/2014/12/05/deploying-asp-net-mvc-5-on-windows-server-2008/
2. http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html

Dan
0
 

Author Comment

by:joachim58
ID: 41795954
Dan,
thank you very much for your comment. Using the first link you listed the problem could be solved.
regards
Joachim
0
 
LVL 28

Expert Comment

by:Dan McFadden
ID: 41795957
Glad to have helped.

Dan
0
 

Author Closing Comment

by:joachim58
ID: 41803621
Problem solved. Thank you.
0

Featured Post

10 Questions to Ask when Buying Backup Software

Choosing the right backup solution for your organization can be a daunting task. To make the selection process easier, ask solution providers these 10 key questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What You Need to Know when Searching for a Webhost Provider
When the s#!t hits the fan, you don’t have time to look up who’s on call, draft emails, call collaborators, or send text messages. An instant chat window is definitely the way to go, especially one like HipChat. HipChat is a true business app. An…
Learn how to set-up custom confirmation messages to users who complete your Wufoo form. Include inputs from fields in your form, webpage redirects, and more with Wufoo’s confirmation options.
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.
Suggested Courses

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question