2013-03-22 109 views
0

我有一個wcf服務。 它使用本地IIS服務器。錯誤500.19本地IIS

我的web.config是:

<?xml version="1.0"?> 
<configuration> 
    <system.web> 
    <authentication mode="Windows"/> 
    <compilation debug="true" targetFramework="4.0" /> 
    </system.web> 
    <system.serviceModel> 
    <bindings> 
     <customBinding> 
     <binding name="InstantMessagingBinding" closeTimeout="00:00:45"> 
      <textMessageEncoding> 
      <readerQuotas maxStringContentLength="200000" maxArrayLength="200000" /> 
      </textMessageEncoding> 
      <httpTransport keepAliveEnabled="false" maxReceivedMessageSize="200000" authenticationScheme="Ntlm"/> 
     </binding> 
     </customBinding> 
    </bindings> 
    <behaviors> 
     <serviceBehaviors> 
     <behavior name="InstantMessagingBehavior"> 
      <serviceMetadata httpGetEnabled="true" /> 
      <serviceDebug includeExceptionDetailInFaults="true" /> 
     </behavior> 
     </serviceBehaviors> 
    </behaviors> 
    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" /> 
    <services> 
     <service name="Isima.InstantMessaging.WcfService.ContactService" behaviorConfiguration="InstantMessagingBehavior"> 
     <endpoint address="" 
      binding="customBinding" bindingConfiguration="InstantMessagingBinding" 
      contract="Isima.InstantMessaging.WcfService.IContactService" > 
      <identity> 
      <dns value="localhost" /> 
      </identity> 
     </endpoint> 
     </service>   
    </services> 
    </system.serviceModel> 
    <system.webServer> 
    <modules runAllManagedModulesForAllRequests="true"/> 
    </system.webServer> 
</configuration> 

當我跑我的服務,我得到一個錯誤 enter image description here

此錯誤是關於「可能會出現此問題時,IIS的指定部分配置文件被鎖定在更高級別的配置中。「

爲什麼會出現此錯誤?

回答

0

檢查是否爲IIS安裝了所有應用程序開發組件。例如.NET和ASP.NET。請參閱控制面板中的添加/刪除窗口功能對話框,並檢查已安裝的IIS組件。

我總是安裝所有的開發組件(ASP.NET,...)。