IIS 认为 ASP.NET 4.0 正在运行,但事实并非如此?

问题描述 投票:0回答:1

我收到有关无法运行 websockets 的错误

Exception information: 
    Exception type: InvalidOperationException 
    Exception message: WebSockets is unsupported in the current application configuration. To enable this, set the following configuration switch in Web.config:
<system.web>
  <httpRuntime targetFramework="4.5" />
</system.web>

奇怪的是,表面上的机器没有 4.0(也不是 4.5),而是运行 4.8,没有硬编码到特定版本(这就是他们在错误中建议的)我如何让 IIS 意识到这一点有足够新的版本来完成它需要做的事情吗?

我查看了注册表,可以看到版本显示正确,所以我有点困惑,我的 Google-foo 让我失望了:-)

registry setting

app-pool setting

asp.net iis websocket .net-framework-version
1个回答
0
投票

分配给您的应用程序的应用程序池在 IIS 管理控制台的应用程序池文件夹中显示 NET 版本:

IIS 管理控制台:服务器 - 应用程序池 [1]:https://i.sstatic.net/rUhJP1tk.png

© www.soinside.com 2019 - 2024. All rights reserved.