Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Moved my ASP.NET website to IIS 8 on windows server 2012... services missing: .svc files are viewable, but their methods give a 404

I moved from IIS 6 on windows server 2003.

I can browse to the .svc files. I get a nice standard "This is a Windows© Communication Foundation service" page if I go to http://example.com/Service.svc in a browser.

But I can't browse to any of the methods - I get a 404 error if I go to http://example.com/Service.svc/Method?parameter=xyz in a browser.

Has anyone seen anything like this? Any ideas or suggestions?

I thought I might have a similar problem to this question: WCF on IIS8; *.svc handler mapping doesn't work

But the symptoms are different (looks like they can't see .svc files at all) and none of the solutions work (I have Http Activation for WCF features installed, etc).

like image 334
MGOwen Avatar asked Oct 16 '14 06:10

MGOwen


People also ask

How do I browse an SVC file in IIS?

Solution: Open IIS Manager (Start > Run > search "inetmgr"). Browse from the top level server to Sites and expand the Default Web Site. Select each of the Revit Server applications, and in the Content View, right click on the SVC file and select Browse.


1 Answers

Please check if your IIS has svc handler added.

WCF services don’t run on IIS 8 with the default configuration, because the webserver doesn’t know, how to handle incoming requests targeting .svc files. You can teach it in two steps:

  1. Add a new MIME type:

Extension: .svc MIME type: application/octet-stream

enter image description here

  1. Add a new Managed HTTP Handler:

    Request path: *.svc Type: System.ServiceModel.Activation.HttpHandler Name: svc-Integrated

enter image description here

Refresh your website/web application

References:

http://gyorgybalassy.wordpress.com/2012/09/24/publishing-a-wcf-service-on-iis8/

http://proq.blogspot.hk/2012/09/wcf-on-iis-and-windows-8.html

http://forums.iis.net/t/1200413.aspx?+svc+missing+can+t+find+Module+to+load+within+Handler+Mapping+IIS+8+0

like image 81
Pranav Singh Avatar answered Oct 22 '22 11:10

Pranav Singh