I'm running an ASP.Net application in a Windows 2003 Enterprise Server
environment. I compiled and debugged the web app on our test server
and then deployed it to the production server.
The web app is impersonating a domain account user, with username and
pw supplied in the web.config.
On the test server everything runs fine, whether debugging or accessing
remotely from a browser. However, on the production system, I get the
exception below...
I did some experimentation and found that if I change the app pool the
web app is running under to run as a local service or local system
account it works.
I can't get it to run under the Network Service Account though.
The server that I develop on is identical (as far as I know) to the
target machine.
-Jeremy
The exception:
----------------------------------------------
Mutex could not be created.
Description: An unhandled exception occurred during the execution of
the current web request. Please review the stack trace for more
information about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: Mutex could not be
created.
Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.
Stack Trace:
[InvalidOperationException: Mutex could not be created.]
System.Web.Compilation.CompilationMutex..ctor(Bool ean initialOwner,
String name, String comment) +245
System.Web.Compilation.CompilationLock..cctor() +112
[TypeInitializationException: The type initializer for
"System.Web.Compilation.CompilationLock" threw an exception.]
System.Web.UI.TemplateParser.GetParserCacheItemInt ernal(Boolean
fCreateIfNotFound) +20
System.Web.UI.TemplateParser.GetParserCacheItem() +32
System.Web.UI.ApplicationFileParser.GetCompiledApp licationType(String
inputFile, HttpContext context, ApplicationFileParser& parser) +171
System.Web.HttpApplicationFactory.CompileApplicati on(HttpContext
context) +43
System.Web.HttpApplicationFactory.Init(HttpContext context) +484
System.Web.HttpApplicationFactory.GetApplicationIn stance(HttpContext
context) +170
System.Web.HttpRuntime.ProcessRequestInternal(Http WorkerRequest wr)
+414
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2032;
ASP.NET Version:1.1.4322.2032