aspnet5 vNext(rc1)iis 8 - 糟糕的网关502.3

时间:2015-12-04 21:56:03

标签: iis asp.net-core dnx kestrel-http-server

我意识到这样的帖子存在,我已阅读/重读,但仍然有问题。大多数都是旧的或没有直接相关的,所以我想我会重新发布一个当前的例子。

尝试在win server 2012 R2上运行IIS 8.5+中的基本站点。此时我被困在“ 502.3 - Bad Gateway ”(错误代码80070002,模块httpPlatformHandler,通知executeRequestHandler,处理程序httpplatformhandler)

相关信息:

  
      
  • dnx 1.0.0-rc1-final clr(x64)
  •   
  • IIS - 已安装/验证HttpPlatformHandler 1.2已安装(v1.2.1959)
  •   
  • IIS - 设置“无托管代码”池/站点
  •   
  • 在服务器本身上,如果我直接从命令行运行“kestrel.cmd”(通过dnu发布生成)并导航到该站点,我可以显示该站点。      
        
    • Project.json:
    •   
  •   
{
  "version": "1.0.0-*",
  "dependencies": {
    "Microsoft.AspNet.Server.Kestrel": "1.0.0-rc1-final",
    "Microsoft.AspNet.IISPlatformHandler": "1.0.0-rc1-final",
    "Microsoft.AspNet.StaticFiles": "1.0.0-rc1-final"
  },
  "commands": {
    "kestrel": "Microsoft.AspNet.Server.Kestrel"
  },
  "frameworks": {
    "dnx451": {}
  },
  "publishExclude": [
    "node_modules",
    "bower_components",
    "**.xproj",
    "**.user",
    "**.vspscc"
  ],
  "exclude": [
    "www",
    "node_modules",
    "bower_components"
  ],
  "scripts": {
    "prepublish": [
      "npm install",
      "bower install"
    ]
  }
}
  
      
  • 在dnu发布后生成的Web.config:
  •   
<configuration>
  <system.webServer>
    <handlers>
      <add name="httpplatformhandler" path="*" verb="*" modules="httpPlatformHandler" resourceType="Unspecified" />
    </handlers>
    <httpPlatform processPath="approot\kestrel.cmd" arguments="" stdoutLogEnabled="true" stdoutLogFile="logs\stdout.log" forwardWindowsAuthToken="false" startupTimeLimit="3600"></httpPlatform>
  </system.webServer>
</configuration>

非常感谢您的帮助。

1 个答案:

答案 0 :(得分:0)

我遇到了同样的问题 - iis 8 - 糟糕的网关502.3。

我开启或关闭了Windows功能并启用了IIS。

我清理并重建了解决方案,它就像一个魅力。

我希望它对你有所帮助。