IIS HTTP 错误 500:无法访问请求的页面,因为相关配置数据无效

Hus*_*man 8 asp.net iis application-pool http-error asp.net-core

我已经在本地机器(Windows 10)上的 IIS(版本 10)上成功发布了一个 ASP.NET Core 网站并浏览了它。

但是,当我将它部署在另一台 PC 上的 IIS 上(使用相同版本)时,它给出了HTTP 错误 500.19

在此处输入图片说明

我使用的是相同的Web.config,并IIS_IUSRS有两个虚拟目录和配置文件的权限。我还将应用程序池“IIS AppPool/MyPool”的权限添加到虚拟目录中。这是 web.config:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.webServer>
    <handlers>
      <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
    </handlers>
    <aspNetCore processPath="dotnet" arguments=".\IdentityServer.dll" stdoutLogEnabled="true" stdoutLogFile=".\logs\stdout" forwardWindowsAuthToken="false" />
  </system.webServer>
</configuration>
Run Code Online (Sandbox Code Playgroud)

什么是问题?

Hus*_*man 18

它缺少NET Core Windows Server Hosting bundle,我已经从 web.config "AspNetCoreModule" 中意识到了这一点。

你可以在这里找到链接