怀疑 IIS 6 中会话状态丢失

发布于 2024-10-05 06:06:25 字数 504 浏览 1 评论 0原文

我有一个 ASP.NET 网站,它根据访问的域以多种外观进行响应。

问题在于身份验证和其他一些功能似乎会遇到随机故障,其中用户被发送回登录屏幕,或者其他会话控制值似乎已丢失 - 但仅当通过其中一个域访问时才发生。其他域不会遇到同样的问题。

在我们的测试系统上,通过任何域访问时都不存在问题。在实时情况下,即使遵循相同的步骤,该问题也会在会话期间的不同时间发生。正是由于这些原因,我不认为这是应用软件中的错误。

在问题所在的实时系统上,IIS 中设置了两个网站,每个网站都绑定到所需的域。一个通过 http://mysite.com/myvirtualdir 的虚拟目录访问该站点,另一个通过以下地址访问该站点: http://myalternatesite.com/ 的根路径。不过,我不认为虚拟目录是问题所在。

I have an ASP.NET web site that responds with multiple skins depending on the domain that it is accessed via.

The problem is that authentication and some other features seem to suffer random glitches where the user is sent back to the log in screen, or other session controlled values appear to have been lost - but only when accessed via one of the domains. The other domain does not suffer the same issue.

On our test system, the issues DOES NOT exist when accessing via any domain. On live, the issue will happen at varying times during the session, even with identical steps followed. It is for these reasons that I don't think it is a bug in the application software.

On the live system, where the issue is, two websites are set up in IIS, each with bindings to the required domain. One accesses the site through a virtual directory at http://mysite.com/myvirtualdir, the other accesses the site at the root path at http://myalternatesite.com/. I don't think that the virtual directory is the issue however.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

稍尽春風 2024-10-12 06:06:25

我现在已经解决了我的问题,但仍然不确定确切的原因是什么。

我在 IIS 中打开了两个网站的网站属性,一个有效,一个无效,并比较了属性。

对于解决此问题的其他人,这些是我采取的步骤,按照我认为它们是问题原因的可能性排列。

  1. 第二个网站正在使用默认应用程序池。从我所看到的情况来看,该服务器上的默认应用程序池设置没有什么特别之处,会导致会话丢失,但我现在已更改为使用与一直运行的网站相同的应用程序池。

  2. 禁用 Windows 身份验证以匹配工作网站。

  3. 更改了默认文档,以便仅列出所需的文档。

  4. 连接数限制为 500 个,以匹配工作网站。

希望这对其他人有用。

I've now solved my problem, though still not sure what the exact cause was.

I opened up website properties for the two websites in IIS, the one that worked and the one that didn't and compared properties.

For anyone else trouble shooting this issue, these are the steps that I took, in order of how likely I think they were to be the cause of the issue.

  1. Second website was using Default app pool. There is nothing particular about the Default app pool settings on this server that would cause session to be lost from what I can see, but I have now changed to use the same app pool as the site that was working all along.

  2. Disabled windows authentication to match the working website.

  3. Changed default documents so that only the required document was listed.

  4. Limited connections to 500 to match the working website.

Hope this is of use to somebody else.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文