Rebuild master database

  • Has someone rebuilt master database? Could you nicely post the detail procedures?

    Many thanks in advance.

  • Copy SQL Server install CD to the server. (required for the master db rebuild process)

     

    In cluster admin make all sure SQL Server services are down and all connection pools are stopped to the application databases. If not clustered go into Services and stop MSSQLSERVER, MSDTC, SQLServerAgent, MSSEARCH services.

     

    Now we must rebuild an empty master db since it is corrupt. This will also rebuild model and msdb automatically. (this requires the SQL Server install CD to be available on CD or disk. Also, make sure you have the correct edition of SQL server CD Standard or Enterprise edition)

    To rebuild the master database for a corrupt master db.

    1. Using the SQL Server install CD, copy the Data folder that is in the I86 folder to the hard drive of the server. Go into the folders properties and remove the Read Only attribute from it. (this will cause an error on restore if you do not do this MSFT KB article 273572 )
    2. Shutdown Microsoft® SQL Server 2000, and then run Rebuildm.exe. This is located in :

     Program Files\Microsoft SQL Server\80\Tools\Binn directory via Start, Run, cmd, navigate to this file and run it. If this is a cluster make sure you are logged onto the server that currently owns the SQL Server services.

    1. In the Rebuild Master dialog box, click Browse.
    2. In the Browse for Folder dialog box, select the Data folder from Step 1 and then click OK.
    3. Click Settings if install is not using the standard install defaults. In the Collation Settings dialog box, verify or change settings used for the installation. Make sure the server name to rebuild master is correct and the path to the mssql folder is using the correct drive letter also.

     6. In the Rebuild Master dialog box, click Rebuild to start the process.

    The Rebuild Master utility reinstalls the master,model, msdb, pubs, and northwind databases.

     

    Now you have an empty master/msdb. You must restore them from a valid backup to get the data back into them.

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply