At some random point during the weekend, SQL Server (SQL Server 2008 R2) stopped, and users were no longer able to connect. Investigated the server, and service wasn’t started. Tried starting manually (Run->cmd->service.msc->SQL Server->Start), but got this error:
Windows could not start the SQL Server (MSSQLSERVER) on Local Computer. For more information, review the System Event Log. If this is a non-Microsoft service, contact the service vendor, and refer to service-specific error code 1814.
Looked in the error log, and this was the more ‘service-specific’ error:
The SQL Server (MSSQLSERVER) service terminated with service-specific error The specified resource name cannot be found in the image file..
Which was even less helpful.
Checked the SQL Server error log (C:\Program Files\SQL Server\MSSQL10_50.MSSQLServer\MSSQL\Log\ERRORLOG\), which had various information, the important stuff being:
Error: 927, Severity: 14, State: 2.
Database 'model' cannot be opened. It is in the middle of a restore.
Could not create tempdb. You may not have enough disk space available. Free additional disk space by deleting other files on the tempdb drive and then restart SQL Server. Check for additional errors in the event log that may indicate why the tempdb files could not be initialized.
Tried different Logon Accounts, tried restarting server, same error. Finally after googling, was able to piece together various solutions, and this worked:
C:\Users\administrator>net start mssqlserver /T3608
The SQL Server (MSSQLSERVER) service is starting.
The SQL Server (MSSQLSERVER) service was started successfully.
C:\Users\administrator>sqlcmd -e
1> restore database model
2> go
restore database model
RESTORE DATABASE successfully processed 0 pages in 0.257 seconds (0.000 MB/sec).
1> exit
C:\Users\administrator>
Restarted the server, for good measure, and all is working fine. I have no idea what went wrong, but at least with a few simple commands it started working again. sigh.
UPDATE 10/11/2012: Seems issue is with creating a backup maintenance plan and checking “backup tail of the log option” of the transaction log portion. This can put various Databases into Restore mode, which they can hang. If you can get into SSMS using the normal (Start Menu) or the method above (first cmd and start sql in /T3608 mode) then running this command fixed my issues: “RESTORE DATABASE model WITH RECOVERY”. Source