在应用程序级别之外使用注册为allowDefinition ='MachineToApplication'的部分是错误的 [英] It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level

查看:232
本文介绍了在应用程序级别之外使用注册为allowDefinition ='MachineToApplication'的部分是错误的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Configuration Error 
Description: An error occurred during the processing of a configuration file
required to service this request. Please review the specific error details 
below and modify your configuration file appropriately. 

Parser Error Message: It is an error to use a section registered as
allowDefinition='MachineToApplication' beyond application level.  
This error can be caused by a virtual directory not being configured 
as an application in IIS.

Source Error: 

Line 36:             ASP.NET to identify an incoming user. 
Line 37:         -->
Line 38:        <authentication mode="Windows"/>
Line 39:        <!--
Line 40:             The <customErrors> section enables configuration 

网上有很多关于此错误的引用,但所有这些引用都重复了相同的2个建议,在我的情况下都不适用。

There are lots of references for this error on the web, but all of them repeat the same 2 suggestions, neither of which applies in my case.

这是我的方案。

我有一个带有IIS的Server 2003 6.默认Web站点有4个虚拟目录,它们都配置为单独的应用程序。有些是Web服务,有些是纯ASP.NET站点。其中3个工作正常,一个没有 - 从外部(当我登录到服务器并浏览localhost时我没有收到此错误。)

I have a Server 2003 with IIS 6. The default web site has 4 virtual directories that are all configured as separate applications. Some are Web Services, some are plain ASP.NET sites. 3 of them work just fine, one does not - from the outside (I do not get this error when I am logged on to the server and browse localhost).

全部应用程序共享相同的应用程序池,它们都有自己的web.configs。我查看了很长的属性,但没有找到可以解释错误的区别。安全设置是相同的。我检查了MMC和文件系统中文件和文件夹的权限。应用程序池帐户(NETWORK SERVICE)和匿名Web用户都具有所需的访问权限,并且它们在所有应用程序中都是相同的。
两个应用程序都启用了匿名访问并启用了集成安全性。

All applications share the same app pool, and they all have their own web.configs. I looked at the properties in great length and I did not find a difference that would explain the error. the security settings are the same. I checked the permissions of the files and folders in both MMC and the file system. Both the app pool account (NETWORK SERVICE) and the anonymous web user have the required access rights, and they are the same across all applications. Both applications have anonymous access enabled and integrated security turned on.

同样,当我从防火墙外部点击页面时,我只收到上述错误,如匿名用户。当我在本地登录时,页面服务很好。
这让我觉得这个问题与安全/冒充有关。

Again, I only get the above error when I hit the page from outside the firewall, as the anonymous user. When I am logged on locally, the page is served just fine. Which makes me think that the problem is related to security/impersonation.

无法运行的应用程序是从VS 2008和.Net构建并部署的3.5。它在web.config中有其他旧的应用程序没有的东西。我尝试逐步从web.config中删除设置,直到该网站完全无法工作,无济于事。

The application that does not work was built with and deployed from VS 2008 and .Net 3.5. It has things in the web.config that the other, older applications do not have. I tried to gradually remove settings from the web.config, though, until the site no longer worked at all, to no avail.

发生了什么事?

推荐答案

由于情况经常如此,我忽略了一个小细节 - 一个防火墙规则,将我的请求转发到另一个网站上不同的港口。外部请求实际上是在此服务器上的另一个站点此其他站点 not 已为虚拟目录配置了应用程序。一旦我关闭了另一个网站,这一点立刻变得明显。

As it is so often the case, I had overlooked a small detail - a firewall rule that forwarded my request to a different web site on a different port. External requests actually hit another site on this server. This other site did not have an application configured for the virtual directory. Once I turned the other site off, this became apparent right away.

这篇关于在应用程序级别之外使用注册为allowDefinition ='MachineToApplication'的部分是错误的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆