【问题标题】:HTTP Error 500.19 - Internal Server Error 0x800700b7HTTP 错误 500.19 - 内部服务器错误 0x800700b7
【发布时间】:2015-11-12 06:28:50
【问题描述】:

我正在尝试发布网络服务,但我收到错误消息:

HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.

我有以下详细信息:

Module  DefaultDocumentModule
Notification    ExecuteRequestHandler
Handler StaticFile
Error Code  0x800700b7
Config Error    Cannot add duplicate collection entry of type 'add' with unique key attribute 'value' set to 'KWebService.asmx'
Config File \\?\C:\inetpub\wwwroot\KWebService\web.config
Requested URL   http://localhost:80/KWebService/KWebService
Physical Path   C:\inetpub\wwwroot\KWebService
Logon Method    Anonymous
Logon User  Anonymous

哪个指向行:

   13:             <files>
   14:                 <add value="KWebService.asmx" />
   15:             </files>

我已将 KWebService 文件夹保存在路径 C:\inetpub\wwwroot\KWebService。 我的 web.config 是:

<?xml version="1.0" encoding="utf-8"?>
<!--
  Pour plus d'informations sur la configuration de votre application ASP.NET, consultez
  http://go.microsoft.com/fwlink/?LinkId=169433
  -->
<configuration>
  <system.web>
    <compilation debug="true" targetFramework="4.0" />
    <httpRuntime targetFramework="4.0" />
  </system.web>
    <system.webServer>
        <defaultDocument>
            <files>
                <add value="KWebService.asmx" />
            </files>
        </defaultDocument>
        <directoryBrowse enabled="true" />
    </system.webServer>
</configuration>

我的 IIS 管理器有这个截图:

我使用的端口号是 80 并且 targetFramework="4.0" 并且在应用程序池中我有这个版本的快照:

有人可以告诉我问题的原因吗?

【问题讨论】:

标签: asp.net web-services iis-7 web-config


【解决方案1】:

Erreur HTTP 500.19 - 内部服务器错误

您必须检查“Version du CLR .NET”或“.NET Version”中是否有版本

【讨论】:

    【解决方案2】:

    您收到此错误是因为您在更高级别的配置文件中有类似的条目。它可以在服务器或网站级别。尝试将以下内容放在您的 web.config 文件中的标记下方。

    &lt;remove name="KWebService.asmx" /&gt;

    如果您不想放置上述条目,那么您也可以尝试在更高级别的配置文件中找到重复的条目,例如 applicationhost.config,如果不需要,则将其从那里删除。

    【讨论】:

      猜你喜欢
      • 2012-06-15
      • 2012-06-03
      • 1970-01-01
      • 2015-09-05
      • 2015-09-20
      • 2021-05-09
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多