我的舞台 快乐男声,康师傅茉莉清茶代言人,颁奖在即 尔冬升郑中基为金像奖拜神
大体来说,是环境的问题。
第一个错误,如图:
1. 查了网上说是文件夹权限的问题,依次设置了everyone权限和iis_iuser权限,能勾选的都勾选了,然而并没有什么用,看来不是这个问题导致的。
2. 项目是.net core 2.0,所以想,可能是环境问题,需要安装 aspnetcoremodule托管模块。
>> dotnetcore.2.0.9-windowshosting.exe
>>安装完成后,使用命令重启iis net stop wa
s /y
net start w3svc
>>编辑应用程序池,把.net clr版本设置为无托管代码,如下图:
>>此时不报500.19的错误,改报
http error 502.5 - process failure
common causes of this issue:
• the application process failed to start
• the application process started but then stopped
• the application process started but failed to listen on the configured port
troubleshooting steps:
• check the system event log for error messages
• enable logging the application process' stdout messages
• attach a debugger to the application process and inspect
第二个错误,502.5:
尝试了许多方法。
1. 在folderprofile.pubxml文件中添加节点:
<propertygroup> <publishwithaspnetcoretargetmanifest>false</publishwithaspnetcoretargetmanifest> </propertygroup>
>>重新发布后还是不行。
2. net core sdk没有安装,或者版本安装错误:
进入网站物理路径目录根目录,打开dos 输入命令,直接运行web程序:dotnet xxxweb.dll
dotnet.exe报错,>>计算机中丢失 api-ms-win-crt-runtime-l1-1-0.dll
解决方案:安装visual c++ redistributable for visual studio 2015 组件
下载地址:https://www.microsoft.com/en-us/download/details.aspx?id=48145
>>发布成功了。
微软文档:
参考博客:https://www.cnblogs.com/eggtwo/p/9900613.html
如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复
Net Core Web Api项目与在NginX下发布的方法
asp.net core3.1 引用的元包dll版本兼容性问题解决方案
IdentityServer4实现.Net Core API接口权限认证(快速入门)
ASP.NET Core MVC通过IViewLocationExpander扩展视图搜索路径的实现
网友评论