Restore the deleted master database in SQL2008
1. In the experiment environment, the dc is used, and the. COM password for the SQL2008.DC domain that is added to the domain is P @ ss0rd.
First, create a t1 table in the master database. We do not recommend that you create a table in the work environment. This is only for verification)
Back up the master database of sql2008 and delete the two files of the master database.
1. Rebuild the system database and mount the sql2008 CD.
Enter setup.exe/q/ACTION = REBUILDDATABASE/INSTANCENAME = mssqlserver/SQLSYSADMINACCOUNTS = a \ administrator/SAPWD = P @ ssw0rd
2. After the system database is rebuilt, The SQLServer service can be started, but the content of the original master database is lost, and backup and recovery of the master database is required.
3. After the SQLServer service is stopped, enter the single-user mode.
Enter
Cd "C: \ ProgramFiles \ MicrosoftSQLServer \ MSSQL10_50.MSSQLSERVER \ MSSQL \ Binn"
Enter the path
Sqlservr-c-m
4. Restore the MASTER database
On the SQL console, type RESTOREDATABASEmasterfromdisk = 'C: \ specific backup file name'
At this time, we can verify that the master database has table t1!
This article is from "perfect world !" Blog, please be sure to keep this source http://shyln.blog.51cto.com/6890594/1302928