随机401错误的自动编译asp.net网站时更新网页推错误、网页、网站、net

2023-09-09 21:09:45 作者:还是来不及 ゛

我们都被部署在多个IIS服务器上asp.net网站。该网站是编译按需而不是一个pre-编译Web应用程序。

We have an asp.net web site that is deployed on several IIS servers. The site is compile-on-demand as opposed to a pre-compiled web application.

通常部署去罚款,但现在每一次我们得到了一个401的其中一台服务器部署的网页之一。没有什么特别的哪个页面或哪个服务器除了事实,这是一般,它恰好,高流量的页面

Normally deployments go fine but every now and again we get a 401 for one of the deployed pages on one of the servers. There is nothing special about which page or which server apart from the fact that it's generally the higher traffic pages that it happens to.

要纠正这个问题的唯一办法是重新部署在同一个页面。

The only way to rectify this is to deploy the same page again.

ACL访问控制列表看起来很好的文件本身这样的想法是,有一个文件中的ASP.NET临时文件夹锁定问题,当特定的页面重新编译。

The ACLs look fine on the files themselves so the thought is that there is a file locking issue in the Temporary ASP.NET Files folder when the specific page is re-compiled.

在有没有人看到了这一点,或有任何建议,如何避​​免这种情况?

Has anyone seen this before or have any suggestions how to avoid this?

注:这似乎只因为我们搬到了.NET 4.0中已经发生

Note: This only seems to have happened since we moved to .net 4.0

据我可以告诉大家已经看到了401.3由资源ACL拒绝 http://support.microsoft .COM / KB / 907273 但我一直无法证实这一点。

As far as I can tell we are getting a 401.3 Denied by resource ACL http://support.microsoft.com/kb/907273 But I have not been able to confirm this.

推荐答案

我有几个答案表明一个新的环境中进行部署。这是我们一直在考虑为长期,但它很难证明额外的工作,当我们没有问题,定期部署只有一个或两个文件。我真的更感兴趣的是找出什么是真正发生的事情,以及为什么。

I had several answers suggesting a new environment to deploy. This is something we have been considering for the long term but it's hard to justify the extra work when we regularly deploy only one or two files without a problem. I was really more interested in finding out what is actually happening and why.

在一个变通办法的条款,并在事后,这可能听起来很明显,一个简单的app_pool回收解决了权限问题,是不是测试的问题,并重新部署文件,直到问题消失容易多了。

In terms of a workaround, and this might sound obvious after the fact, a simple app_pool recycle solves the permissions issue and is much easier than testing for the issue and redeploying the file until the problem goes away.