Edit

Share via


Monitor the error logs

Applies to: SQL Server on Windows

SQL Server logs certain system events and user-defined events to the SQL Server error log and the Windows application log. Both logs automatically timestamp all recorded events. Use the information in the SQL Server error log to troubleshoot problems related to SQL Server.

The Windows application log provides an overall picture of events that occur on the Windows operating system, as well as events in SQL Server and SQL Server Agent. Use the Windows Event Viewer to view the Windows application log and to filter the information. For example, you can filter events, such as information, warning, error, success audit, and failure audit.

Compare error and application log output

You can use both the SQL Server error log and the Windows application log to identify the cause of problems. For example, while monitoring the SQL Server error log, you might encounter error messages that don't contain cause information. By comparing the dates and times for events between these logs, you can narrow the list of probable causes.

The SQL Server Management Studio Log File Viewer lets you integrate SQL Server, SQL Server Agent, and the Windows logs into a single list, making it easy to understand related server events and SQL Server events. For more information, see View the SQL Server error log in SQL Server Management Studio (SSMS).

In this section

Article Description
View the SQL Server error log Contains information about the SQL Server error log and how to view it.
View the Windows Application log to troubleshoot SQL Server Contains information about the Windows application log and how to view it.