SQL Server – Did not autostart

Background

We have Windows Patches automatically applied.  Often during the application, the machine restarts once or more.

As SQL Server is set for auto-start, the SQL Server instance should come back up online.

 

Problem

Unfortunately, our SQL Server Instance is not auto-starting.

 

What triggered prior shutdown

Event Viewer

As alway, it is good to review Windows Event Viewer and see what is logged.

Windows Logs

Windows Logs – Setup

Image

Explanation
  1. A reboot is necessary before package KB4014512 can be changed to the Installed state.
    • Log Name :- Setup
    • Source :- Servicing
    • Event ID :- 4
    • Level :- Information
    • User :- SYSTEM

 

Is Shutdown Logged

SQL Server Shutdown

Event ID :- 17147 = SQL Server is terminating because of a system shutdown

Image

Explanation

  1. SQL Server is terminating because of a system shutdown. This is an informational message only. No user action is required.
    • Log Name :- Application
    • Source :- MSSQLSERVER
    • Logged :- 2017-June-3rd 1:32 AM
    • Event ID :- 17147
    • Level :- Information
    • User :- N/A

 

Conclusion

We see that SQL Server is gracefully shutting down based on request for system shutdown.

The actual user is not noted and so we can only assume it is carried by the system itself.

The shutdown occurred on Saturday June 3rd @ 1:30 Saturday morning.

 

 

Is SQL Server Startup Logged ?

SQL Server StartUp

Event ID :- 17126 = SQL Server is now ready for client connections

Image

 

Explanation

  1. SQL Server is now ready for client connections. This is an informational message; no user action is required
    • Log Name :- Application
    • Source :- MSSQLSERVER
    • Logged :- 2017-June-3rd 9:44 PM
    • Event ID :- 17126
    • Level :- Information
    • User :- N/A

Conclusion

We see that SQL Server was started on Saturday June 3rd, 2017 @ 9:44 PM

 

Problem Areas

The problem areas are when SQL Server shuts down ( Event ID : 17147), but does not come back up ( Event ID :- 17126).

SQL Server

SQL Server – Error Log

Was a restart attempted between once the system came back?

Let us check whether a restart was attempted.  We will rely on SQL Server Error Logs…

SSMS – Management – SQL Server Logs

 

Logs Timeline
  1. SQL Server Error Logs Lineage
    • Current 6/3/2017 9:44 PM
    • Archive #1 – 6/3/2017 1:32:00 AM
    • Archive #2 – 5/31/2017 12:56 PM
Explanation

SQL Server Instance shut down Saturday June 3rd @ 1:32 AM.

Unfortunately, SQL Server Instance restart was not automatically attempted.

Restart did not occur until manually triggered on June 3rd @ 9:44 PM

 

Remediation Options

  1. Change SQL Server Startup
    • Change SQL Server Startup from “Automatic” to “Automatic Delay Start
      • Automatic Delay Start occurs 1 to 2 minutes after all auto services are started

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s