This can be a bit tricky... mostly because all of the information I ran across with the exception of one didn't work. So, you find that you can no longer access your database because both SQL Agent and MSSQL Server are both not running. When you attempt to start the services, you're presented with errors. If you dig into the errors, you eventually find that you have an inaccessible MASTER database. What do you do to remedy this problem?
Rebuild the master database. Unfortunately, MSSQL 2005 does NOT come with a handy utility to accomplish a master db rebuild like MSSQL 2000 did. Instead, you're forced to run a sort of cryptic rebuild using "setup.exe" from the command-line.
I found the following statement didn't work for me, because it was looking for a "valid SqlRun_SQL.msi" that it cannot locate:
start /wait setup.exe /qn INSTANCENAME=MSSQLSERVER REINSTALL=SQL_Engine REBUILDDATABASE=1 SAPWD=mypassword
So, much later in the day and much troubleshooting and hair pulling later, I found a site that actually addressed the problem. As of the writing of this article, I found that Microsoft has an article on this already at:
http://support.microsoft.com/kb/943635
There, you can see the difference and that the original installation location is of paramount importance.
start /wait Original_Location\setup.exe /qn INSTANCENAME=Instance_Name REINSTALL=SQL_Engine REBUILDDATABASE=1 SAPWD=StrongPassword







