Day 23: Detach database Errors

Day 23: Detached Errors

Microsoft recommend that you move databases by using the ALTER DATABASE planned relocation procedure, instead of using detach and attach. ALTER DATABASE (Transact-SQL). “

We cannot detached system databases:

Server: Msg 7940, Level 16, State 1, Line 1
System databases master, model, msdb, and tempdb cannot be detached.

To work on attached/detached msdb/model databases need to enable startup parameter “-c -m -T3608“

http://msdn.microsoft.com/en-us/library/ms190794.aspx

also you cannot detached the databases which are in used, and are configured for :

Replication

Mirroring

Log shipping

Database Snapshot

                Suspect database

To attach the database you should properly detach the database. And then re-attach on the same server or move the database files and re-attached on a different server.

Advertisements
This entry was posted in Troubleshooting and tagged . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s