We have a SQL Server that is used internally for testing. We shut down the server every night to save on Azure costs. Sometimes it fails to startup due to the paths it uses not being available like the temporary D drive. When someone reports they cannot access the server I login and start the server up manually which works fine.
I have set SQL Server in Windows Services - Recovery tab to restart the server on first and second failure after 5 minutes, but this does not seem to work. Does this only kick in after it has started the first time and crashed?
I have also changed the startup type to Automatic (Delayed Start) which I am hoping will solve the issue.
But fundamentally this server is used primarily for the SQL Server and the solution I want is for Windows to attempt every 5 minutes to start the SQL Server if it has not managed to startup. Even better would be to email me if it fails after 30 minutes.
I could write something in PowerShell to achieve this, but I'm wondering is there something out of the box I could be doing?