ServiceStack with IIS 7.5

流过昼夜 提交于 2019-11-30 03:17:55

问题


I installed Clean Windows Web Server 2008 R2 64-bit with IIS 7.5. I created .NET v4.0 application pool and Web Site in this pool, where I deployed my application with ServiceStack services. I got this error message in web browser when I opened servicestack page.:

HTTP Error 500.21 - Internal Server Error
Handler "ServiceStack.Factory" has a bad module "ManagedPipelineHandler" in its module list.

My application is working in Visual studio hosted IIS server. Can be problem with IIS 7.5 instalation and servicestack or it is some asp.net issue?


回答1:


1) Ensure the following is in the web.config

<!-- Required for IIS 7.0 -->
<system.webServer>
  <handlers>
    <add path="*" 
         name="ServiceStack.Factory"
         type="ServiceStack.WebHost.Endpoints.ServiceStackHttpHandlerFactory, ServiceStack" 
         verb="*" preCondition="integratedMode"
         resourceType="Unspecified" allowPathInfo="true" />
  </handlers>
</system.webServer>

copied from http://www.servicestack.net/ServiceStack.Hello/

2) If still not working then try running this command

%windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe -i

See the article in comments that vaclamar found.



来源:https://stackoverflow.com/questions/13030418/servicestack-with-iis-7-5

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!