Rebuild SQL Server Master Databases in Less than 5 Minutes

  • Ah, so he did. Clever fellow. :hehe: I will edit the post to remove the "please credit me" comments.

  • Just goes to show how there are many ways to get the same job done.

    Thanks for your comments,

    Rudy

    Rudy

  • This tip/how-to assumes that you can connect to the SQL Server instance. If I lost the master database, being able to connect would be the first thing I would worry about. Maybe you mean that if I move the copies I made before the accident back to replace the damaged master files, then I could connect. I have not had that experience yet. In any case, this looks like a good, solid tip.

    Thank You,

    David Shink

  • Yes, but do a copy action not a move action, to ensure the destination folder's security settings are applied to the files. The DBA team I am part of has been relying on the method I described for two years of DR exercises and it has always worked. Our daily backup generates fresh copies of the System Database files every day (as soon as the backups are created, we via restore each to a different db name and file location then detach the new db).

    For a recovery, we no longer restore the System Dbs from backups - we just copy the most recent copies of the files back into the original location(s) and then start up the engine. The only catch we have encountered is that you have to take ownership of the detached files and grant yourself access to them before you can copy them (upon detach, SQL Server reduces the rights to the MDF and LDF files so that only the identify that detached them has any access).

    😎

  • Larry:

    I am somewhat of a newbie to SQL Server database administration. Your last post is just the sort of thing I would need if I really lost the master database, and users, and my manager were standing over me asking when it will be "fixed". I guess we have all been there. Thank you for taking the time.

    David Shink

Viewing 5 posts - 31 through 34 (of 34 total)

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