Quick Diagnosis Method for "Access Denied" Errors
Author:Eve Cole
Update Time:2009-06-30 15:58:54
When publishing ASP.NET or ASP applications, you often encounter problems caused by improper NTFS authorization. Such problems are usually a headache to debug and require debuggers to have extensive experience. (For example, you need to understand the process model of ASP.NET, the directories that Shadow Copy may involve, and when ASP only reports a "resource in use" error, it may refer to ASP loading a dll in an anti-virus software directory at startup. file failed, etc.)
I just discovered that the debugging process of such problems can be greatly simplified with the help of a small tool filemon at http://www.sysinternals.com/ .
Filemon can monitor and display various file operations of all processes in the system in real time, such as opening/creating a file and loading a dll. filemon monitors these operations and prints their results.
When we encounter a permission exception in a web application, we only need to open filemon, then re-run the web application, and then search in the filemon log to find the corresponding operation for the Access Denied exception.