IIS抱怨一个locking的部分 – 我怎样才能找出它被locking的地方?
我在我的web.config中有这个部分: <system.webServer> <modules runAllManagedModulesForAllRequests="true" /> <security> <authentication> <anonymousAuthentication enabled="true" /> <windowsAuthentication enabled="true" /> </authentication> </security> </system.webServer> IIS7崩溃并抱怨自动化部分: 模块AnonymousAuthenticationModule 通知AuthenticateRequest 处理程序StaticFile 错误代码0x80070021 configuration错误此configuration部分不能用于此path。 当部分locking在父级别时,会发生这种情况。 locking可以是默认的(overrideModeDefault =“Deny”),也可以通过overrideMode =“Deny”或legacy allowOverride =“false”的位置标签进行显式设置。 Config Source 69: <authentication> 70: <anonymousAuthentication enabled="true" /> 所以解决这个问题的常用方法是进入%windir%\system32\inetsrv\config\applicationHost.config并解锁部分: <sectionGroup name="system.webServer"> <sectionGroup name="security"> <section name="access" overrideModeDefault="Deny" /> <section name="applicationDependencies" overrideModeDefault="Deny" /> <sectionGroup name="authentication"> <section name="anonymousAuthentication" overrideModeDefault="Allow" /> […]