PRB: Access Denied Error When You Make Code Modifications with Index Services Running

Article ID : 329065
Last Review : June 25, 2004
Revision : 3.0
This article was previously published under Q329065

SYMPTOMS

When you access a page after an AppDomain load, for example, when you modify the Bin directory or the Web.config file on computers running Microsoft Index Services, you may receive the following error message:

Server Error in '/MyWebApp' Application

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: Access is denied: 'mydll'.

Source Error:

Line 169:   <add assembly=<System.Drawing, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a>/>

Line 170:    <add assembly=<System.EnterpriseServices, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a>/>
Line 171: <add assembly=<*>/>
Line 172: </assemblies>
Line 173:

Source File: c:/winnt/microsoft.net/framework/v1.0.3705/Config/machine.config Line: 171
Version Information: Microsoft .NET Framework Version:1.0.3705.0; ASP.NET Version:1.0.3705.0

If you right-click the page in the browser, and then click View Source, you see that the HTML source code reveals additional information, including the following call stack.

[FileLoadException]: Access is denied: 'MyWebApp'.<BR/>
at System.Reflection.Assembly.nLoad(AssemblyName fileName, Boolean isStringized, Evidence assemblySecurity, Boolean throwOnFileNotFound, Assembly locationHint, StackCrawlMark&amp; stackMark)<BR/>
at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Boolean stringized, Evidence assemblySecurity, StackCrawlMark&amp; stackMark)<BR/>
at System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark&amp; stackMark)<BR/>
at System.Reflection.Assembly.Load(String assemblyString)<BR/>
at System.Web.UI.CompilationConfiguration.LoadAssemblies(Hashtable original)<BR/>
[ConfigurationException]: Access is denied: 'MyWebApp'.<BR/>
(d:/winxp/microsoft.net/framework/v1.0.3215/Config/machine.config line 145)<BR/>
at System.Web.UI.CompilationConfiguration.LoadAssemblies(Hashtable original)<BR/>
at System.Web.UI.CompilationConfiguration.get_Assemblies()<BR/>
at System.Web.UI.CompilationConfiguration.GetAssembliesFromContext(HttpContext context)<BR/>
at System.Web.UI.TemplateParser.AppendConfigAssemblies()<BR/>
at System.Web.UI.TemplateParser.PrepareParse()<BR/>
at System.Web.UI.TemplateParser.Parse()<BR/>
at System.Web.UI.TemplateParser.GetParserCacheItemThroughCompilation()<BR/>
at System.Web.UI.TemplateParser.GetParserCacheItemInternal(Boolean fCreateIfNotFound)<BR/>
at System.Web.UI.TemplateParser.GetParserCacheItemWithNewConfigPath()<BR/>
at System.Web.UI.TemplateParser.GetParserCacheItem()<BR/>
at System.Web.UI.ApplicationFileParser.GetCompiledApplicationType(String inputFile, HttpContext context, ApplicationFileParser&amp; parser)<BR/>
at System.Web.HttpApplicationFactory.CompileApplication(HttpContext context)<BR/>
at System.Web.HttpApplicationFactory.Init(HttpContext context)<BR/>
at System.Web.HttpApplicationFactory.GetApplicationInstance(HttpContext context)<BR/>
at System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)

CAUSE

If you run Index Server (Cisvc.exe), then Index Server may rescan the Temporary ASP.NET Files directory while it requests a Microsoft ASP.NET page. Cisvc.exe then holds a lock on the Temporary ASP.NET Files directory for one to five minutes. The length of time of the lock depends on the size of the directory that causes the Aspnet_wp.exeprocess (or W3wp.exe process for applications that run on Microsoft Internet Information Services [IIS] 6.0) to not load the particular DLL.

RESOLUTION

If you do not use Index Server on the server, you can disable it. To do so, follow these steps:

1. Click Start, and then click Services.
2. Locate Indexing Service from the list of services, and then click Indexing Service Properties from the subform.
3. On the General tab of the Indexing Service Properties dialog box, in the Startup type drop-down item list, click Disabled.
4. Click OK.

If you use Index Server, you can exclude the Temporary ASP.NET Files
directory from the folders that the Index Server scans. To do so,
follow these steps:

1. Click Start, point to All Programs, point to Administrative Tools, and then click Computer Management.
2. Expand the Services and Applications node, expand the Indexing Service node, and then expand the System node.
3. Right-click the Directories folder, point to New, and then click Directory from the subform to open the Add Directory dialog box.
4. Click Browse,
and then locate the Temporary ASP.NET Files directory. You typically
find the Temporary ASP.NET files in the following path:
c:/<WINDIR>/Microsoft.NET/Framework/<Version Number>/Temporary ASP.NET Files
Note<Version Number> is the version of .NET Framework installed on your computer.
5. Click No under the Include in Index? option buttons.
6. Click OK to close.
7. Close the Computer Management dialog box.
8. Restart the Indexing Services service.

MORE INFORMATION

Other software that is designed to scan directories
at regular intervals may lock the files that are located in the
Temporary ASP.NET Files directory in a manner that is similar to how the
Indexing Service locks the files. Examples of such software include
virus scanners and backup software. Microsoft recommends that you see
the manufacturers' manuals for the individual software for information
about how to disable or to exclude the Temporary ASP.NET Files from
these services.

Parser Error Message: Access is denied【转】的更多相关文章

  1. CREATE FILE encountered operating system error 5(Access is denied.)

    这篇博文主要演示"CREATE FILE encountered operating system error 5(Access is denied.)"错误如出现的原因(当然只是 ...

  2. [解决]Mercurial HTTP Error 500: Access is denied on 00changelog.i

    总之,用户对仓库目录要有写权限 00changelog, access is denied, hg, http error 500, mercurial, permissions, push Merc ...

  3. 网站部署后Parser Error Message: Could not load type 的解决方案

    asp.net 的Webproject 项目是在64bit机上开发,默认选项发布后,部署到32bit的服务器上,出现Parser Error Message: Could not load type的 ...

  4. Distribution setup SQL Server Agent error: "RegCreateKeyEx() returned error 5, 'Access is denied.'" (转载)

    In the Configure Distribution Wizard, the step "Configuring SQL Server Agent to start automatic ...

  5. SQLServer xp_instance_regread returned error 5,Access is denied(配置最小权限)

    公司一套智能巡检系统,客户需要最小的权限去给这套系统使用:配置完后发现很多权限报错,有一条是关于xp_instance_regread读系统注册表error 5的报错.常理error 5.是属于系统权 ...

  6. server error in '/' applecation----Compiler Error Message: CS0016: Could not write to output file 'c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\root\xx' -- 'Access is denied

    今天在阿里云虚拟机上部署新站点后出现下面的错误:server error in '/' applecation Compiler Error Message: CS0016: Could not wr ...

  7. QTP Test ,VAPI-XP Test,LR Test 和ALM 集成远程分布式执行遇到的“access is denied ” “unspecified error”问题

    大家都知道QTP与ALM (QC的升级版)集成是最好的一个分布式执行的结合.因为毕竟QTP是一个商业软件,HP当然不会让你去跟其他的open source的工具去集成,要不他到哪里去挣钱. 有时候服务 ...

  8. Socket Error # 10013 Access denied

    --------------------------- Debugger Exception Notification --------------------------- Project xxx. ...

  9. 一看便知linux下mysql报错ERROR 1044: Access denied for user: '@localhost' to database 'mysql'

    错误信息:ERROR 1044: Access denied for user: '@localhost' to database 'mysql' linux下解决方案: mysql> use ...

随机推荐

  1. [BZOJ3561] DZY Loves Math VI

    (14.10.28改) 本来只想写BZOJ3739:DZY Loves Math VIII的,不过因为和VI有关系,而且也没别人写过VI的题解,那么写下. 不过我还不会插公式…… http://www ...

  2. 内核参数优化之1 keepalive解析

    以下信息纯属虚构,切勿相信! tcp/ip协议中有一个keep-alive机制,即检查空连接的时效性,当一个空连接持续一段时间后,就会发送一个keep-alive探测包,来探测客户端是否还存在. 如果 ...

  3. 命令提示符CMD远程连接Mysql学习笔记

    我想要用Cmd可以像SecureCRT一样远程连接数据库,查询数据,因为用cmd的话可以用批处理,方便脚本调用 第一步:直接使用命令 mysql –h ip –u user –p,本地运行了该命令提示 ...

  4. 判断Python输入是否为数字

    在接收raw_input方法后,判断接收到的字符串是否为数字 例如: str = raw_input("please input the number:") if str.isdi ...

  5. 开发纯ndk程序之环境搭配

    安装ndk 从安卓官网下载,ndk,双击解压到当前文件夹.建议想装在那个文件夹便解压到那个文件夹,而且文件夹的路径中不要有空格,因为gcc编译的时候会把空格前后两个字符串作为两个文件夹来对待. 使用g ...

  6. commons-beanutils使用

    Jakarta Commons项目提供了相当丰富的API,我们之前了解到的Commons Lang只是众多API的比较核心的一小部分而已.Commons下面还有相当数量的子项目,用于解决各种各样不同方 ...

  7. angularjs学习笔记—事件指令

    ngClick 适用标签:所有触发条件:单击 #html <div ng-controller="LearnCtrl"> <div ng-click=" ...

  8. flex

    http://www.w3.org/html/ig/zh/wiki/Css3-flexbox https://developer.mozilla.org/zh-CN/docs/CSS/CSS_Refe ...

  9. 吃午饭前,按书上的代码写会儿--Hunt the Wumpus第一个版本

    有空就要慢慢练起~~~~脑袋动起来是很快乐的事儿....:) <易学PYTHON>演练一遍. from random import choice cave_numbers = range( ...

  10. UART与USART的区别

    UART与USART都是单片机上的串口通信,他们之间的区别如下: 首先从名字上看: UART:universal asynchronous receiver and transmitter通用异步收/ ...