SQL Server reports errors for exceptions, assertions, and hang conditions

Article translations Article translations
Article ID: 2028589 - View products that this article applies to.
Expand all | Collapse all

Symptoms

SQL Server records the following events in the Windows Application Event Log (and SQL ERRORLOG) when execptions, assertions, or hang conditions are detected:

Collapse this tableExpand this table
EventID Message
17065SQL Server Assertion: File: <filename>, line = <n> Failed Assertion = '<expression>'
17066SQL Server Assertion: File: <"filename">, line=<n> Failed Assertion = '<expression>'. This error may be timing-related. If the error persists after rerunning the statement, use DBCC CHECKDB to check the database for structural integrity, or restart the server to ensure in-memory data structures are not corrupted
17067SQL Server Assertion: File: <"filename">, line=<n> Failed Assertion = '<expression>'. This error may be timing-related. If the error persists after rerunning the statement, use DBCC CHECKDB to check the database for structural integrity, or restart the server to ensure in-memory data structures are not corrupted
17310A user request from the session with SPID <n> generated a fatal exception. SQL Server is terminating this session. Contact Product Support Services with the dump produced in the log directory
17311SQL Server is terminating because of fatal exception <exception code>. This error may be caused by an unhandled Win32 or C++ exception, or by an access violation encountered during exception handling. Check the SQL error log for any related stack dumps or messages. This exception forces SQL Server to shutdown. To recover from this error, restart the server (unless SQLAgent is configured to auto restart).
17883Process <process> (<thread id>) Worker <worker address> appears to be non-yielding on Scheduler <n>. Thread creation time: <n>. Approx Thread CPU Used: kernel <n> ms user <n> ms. Process Utilization <n>%. System Idle <n>%. Interval: <n> ms
17884New queries assigned to process on Node <n> have not been picked up by a worker thread in the last <seconds> seconds. Blocking or long-running queries can contribute to this condition, and may degrade client response time. Use the "max worker threads" configuration option to increase number of allowable threads, or optimize current running queries. SQL Process Utilization: <n>%. System Idle: <n>%
17887IO Completion Listener (<threadid> Worker <worker address> appears to be non-yielding on Node <n>. Approx CPU Used: kernel <n> ms, user<n> ms, Interval: <n>
17888All schedulers on Node <n> appear deadlocked due to a large number of worker threads waiting on <wait type> Process Utilization <n>%.

Cause

The cause for these errors is specific to the error. In many cases, assertions and exceptions are caused by a problem with the SQL Server code. Scheduler yielding problems (or hangs) may be a problem with the SQL Server code but can also be a problem with an external module or a thread delayed when calling a Windows API call.

Resolution

Find the context of the error and related stack dump information in the ERRORLOG to search for possible known issues within the Microsoft Knowledge Base. If Error Reporting is enabled, you may receive a response from Microsoft as found in the Event Log indicating a possible solution to the problem.

More information

For more information about the products or tools that automatically check for this condition on your instance of SQL Server and on the versions of the SQL Server product, see the following table:
Collapse this tableExpand this table
Rule software

Rule title

Rule description

Product versions against which the rule is evaluated
SQL Server 2008 R2 Best Practice Analyzer (SQL Server 2008 R2 BPA)





Server Exception or Hang detected on server






The SQL Server 2008 R2 Best Practice Analyzer (SQL Server 2008 R2 BPA) provides a rule to detect if any of the events listed in the Symptoms section are found in the Windows Application Event Log. The SQL Server 2008 R2 BPA supports both SQL Server 2008 and SQL Server 2008 R2.

If you run the BPA tool and encounter an Error with the title of Engine - Server Exception or Hang detected on server, then you have one of the EventID values as listed in the Symptoms section of this article in your Windows Application Event Log. BPA does not filter on any date/time so it will report the number of occurrences of these events in your current Event Log.
SQL Server 2008
SQL Server 2008 R2







SQL Server 2012 Best Practice Analyzer (SQL Server 2012 BPA)





Server Exception or Hang detected on server





The SQL Server 2012 Best Practice Analyzer (SQL Server 2012 BPA) provides a rule to detect if any of the events listed in the Symptoms section are found in the Windows Application Event Log.

If you run the BPA tool and encounter an Error with the title of Engine - Server Exception or Hang detected on server, then you have one of the EventID values as listed in the Symptoms section of this article in your Windows Application Event Log. BPA does not filter on any date/time so it will report the number of occurrences of these events in your current Event Log. 
SQL Server 2012









Properties

Article ID: 2028589 - Last Review: May 7, 2014 - Revision: 3.0
Applies to
  • Microsoft SQL Server 2008 Analysis Services
  • Microsoft SQL Server 2008 Developer
  • Microsoft SQL Server 2008 Enterprise
  • Microsoft SQL Server 2008 Express
  • Microsoft SQL Server 2008 Express with Advanced Services
  • Microsoft SQL Server 2008 R2 Datacenter
  • Microsoft SQL Server 2008 R2 Developer
  • Microsoft SQL Server 2008 R2 Enterprise
  • Microsoft SQL Server 2008 R2 Express
  • Microsoft SQL Server 2008 R2 Express with Advanced Services
  • Microsoft SQL Server 2012 Developer
  • Microsoft SQL Server 2012 Enterprise
  • Microsoft SQL Server 2012 Express
  • Microsoft SQL Server 2012 Standard
  • Microsoft SQL Server 2012 Web
  • Microsoft SQL Server 2014 Developer
  • Microsoft SQL Server 2014 Enterprise
  • Microsoft SQL Server 2014 Express
  • Microsoft SQL Server 2014 Standard
  • Microsoft SQL Server 2014 Web
Keywords: 
KB2028589

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com