1

we are 4 developers (not professional server administrators) and running 2 servers with IIS 8.5 (Windows server 2012 R2) and ASP.NET 4.

Multiple times per day we get this exception in the windows event log:

Application: w3wp.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.AccessViolationException
Stack:
   at System.Web.Hosting.UnsafeIISMethods.MgdIsLastNotification(IntPtr, System.Web.RequestNotificationStatus)
   at System.Web.Hosting.UnsafeIISMethods.MgdIsLastNotification(IntPtr, System.Web.RequestNotificationStatus)
   at System.Web.HttpRuntime.FinishRequestNotification(System.Web.Hosting.IIS7WorkerRequest, System.Web.HttpContext, System.Web.RequestNotificationStatus ByRef)
   at System.Web.HttpRuntime.OnRequestNotificationCompletionHelper(System.IAsyncResult)
   at System.Web.HttpRuntime.OnRequestNotificationCompletion(System.IAsyncResult)
   at System.Web.HttpApplication+PipelineStepManager.ResumeSteps(System.Exception)
   at System.Web.HttpApplication+CallHandlerExecutionStep.OnAsyncHandlerCompletion(System.IAsyncResult)
   at System.Threading.Tasks.Task.Execute()
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef)
   at System.Threading.Tasks.Task.ExecuteEntry(Boolean)
   at System.Threading.ThreadPoolWorkQueue.Dispatch()

The next entry in the event log is this:

Faulting application name: w3wp.exe, version: 8.5.9600.16384, time stamp: 0x5215df96
Faulting module name: iiscore.dll, version: 8.5.9600.17224, time stamp: 0x53b1e5a1
Exception code: 0xc0000005
Fault offset: 0x0000000000002c44
Faulting process id: 0x257c
Faulting application start time: 0x01d05f0c93813e6e
Faulting application path: c:\windows\system32\inetsrv\w3wp.exe
Faulting module path: C:\Windows\system32\inetsrv\iiscore.dll
Report Id: 073f9a19-cb13-11e4-80c3-0cc47a02ce53
Faulting package full name: 
Faulting package-relative application ID: 

The always occur as a pair. I spent hours with google but have no idea if this is a problem in our code or in an external module and how to solve is. The main problem is that one of our servers stops responding from time to time, so I am really interested if this problems belong together.

We log all exceptions, but I cannot find it in our log. I also tried to attach the remote debugger, but I dont get the exception and the debugging really slows down the website.


Edit: I checked all sources to catch exceptions in m application:

  • AppDomain.CurrentDomain.UnhandledException
  • TaskScheduler.UnobservedTaskException
  • Custom Owin Middleware

But I could not find this exception. The next thing I am gonna try is a custom http module. Lets see.

I also found some not warnings in the event log like:

Exception type: HttpException 
Exception message: The remote host closed the connection. The error code is 0x80070057.

or

Exception type: HttpException 
Exception message: A potentially dangerous Request.Path value was detected from the client (:).

These can happen very often, I am confused why they are added to the event log.

2 Answers 2

0

It may be an ASPNET access problem.

Right-click "Computer" --> "Manage"--> "Local Users and Groups" --> "Groups"

Find the "DB2ADMNS" and "DB2USERS" groups.

Add the "ASPNET" user to each of those groups.

7
  • Thanks for your help, but I cannot find these users. We also use a domain server and the application pool has a custom user. Mar 17, 2015 at 10:03
  • You do not have to find it, its a system account. Just add ASPNET there and should enable enough access for ASP.
    – Overmind
    Mar 17, 2015 at 11:18
  • Are you sure? DB2 is a database and when I google for DB2ADMNS I only find the document from IBM, like this one: www-01.ibm.com/support/knowledgecenter/SSEPGG_9.7.0/… Mar 17, 2015 at 11:54
  • When you say 'cannot find these users' you mean the DB groups or the ASPNET user ? ASP user is hidden, not normally visible, but DB groups should be there (may be named differently like DBADMINS and DBUSERS, but they should exist in some form).
    – Overmind
    Mar 17, 2015 at 13:28
  • Sorry, I dont understand it. Why DB2ADMNS? We dont have no sql-database-engine installed and there is no user group with this name. Mar 17, 2015 at 13:59
0

I wouldn't be concerned about

Exception type: HttpException Exception message: The remote host closed the connection. The error code is 0x80070057.

That just means that the remote side went away (crashed? lost connectivity? who knows) while it was receiving data.

I also wouldn't worry about

Exception type: HttpException Exception message: A potentially dangerous Request.Path value was detected from the client (:).

That just means your URL includes a colon, which isn't allowed.

So that leaves the top two error messages. The problem is somewhere in your custom app.

Exception code: 0xc0000005

is an access violation. Either your application's account doesn't have access to everything it needs (application pool? files?) or it attempted to access protected memory. (Someone on this question suggested the problem might also be faulty memory.) Debug Diag (and/or a memory testing utility) can probably help you track down what's causing the issue.

Good luck!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .