我的解决

走了不少歪路,最后发现是没有装 运行环境;

检查你的IIS》"模块"》里是否 存在【AspNetCoreModuleV2】这个东西

如果没有,那么你就需要装 “运行环境”了

运行环境地址:​​https://dotnet.microsoft.com/download/dotnet/5.0​

我的是windows10系统,我选择的是“Windows”》“​​Hosting Bundle​​”  点击这个下载安装

Downloads for ASP.NET Core 5.0 Runtime (v5.0.4)

OS

Installers

Binaries

Linux

​Package manager instructions​

​Arm32​​​ | ​​Arm64​​​ | ​​Arm64 Alpine​​​ | ​​x64​​​ | ​​x64 Alpine​

macOS

 

​x64​

Windows

​Hosting Bundle​​​ | ​​x64​​​ | ​​x86​

​Arm64​​​ | ​​x64​​​ | ​​x86​

安装后再看IIS》模块

asp.net core 5配置IIS报错 HTTP 错误 500.19 - Internal Server Error 错误代码 0x8007000d_运行环境


官方

​https://docs.microsoft.com/zh-CN/troubleshoot/iis/http-error-500-19-webpage​

HRESULT 代码 0x8007000d

错误消息:

应用程序"应用程序名称"中的服务器错误
HTTP 错误 500.19 – 内部服务器错误
HRESULT:0x8007000d
HRESULT 的说明
无法访问请求的页面,因为页面的相关配置数据无效。

原因

出现此问题的原因是,ApplicationHost.config或Web.config文件包含格式错误的 XML 元素。

解决方案

从文件或文件中删除格式ApplicationHost.configWeb.config XML 元素。