SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Corrupt mirror database


Corrupt mirror database

Author
Message
smitty-1088185
smitty-1088185
SSCommitted
SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)

Group: General Forum Members
Points: 1957 Visits: 619
I have a database in recovery mode that was part of a mirroring test. I dropped the mirror on the principal and deleted the mirroring endpoints.
The db still exist in the SQL studio manager but when I run, select * from select * from sys.databases it does not exist. The db does show up in the restore db options.


When I right click on the database and click delete it says:
The database 'Replication_Test' is enabled for database mirroring. Database mirroring must be removed before you drop the database. (Microsoft SQL Server, Error: 3743)

I tried to restore the database with recovery and overwrite enabled and it says:
System.Data.SqlClient.SqlError: RESTORE cannot operate on database 'Replication_Test' because it is configured for database mirroring. Use ALTER DATABASE to remove mirroring if you intend to restore the database. (Microsoft.SqlServer.Smo)


So I run the following command "ALTER DATABASE Replication_Test SET PARTNER OFF" and it says:
Msg 911, Level 16, State 1, Line 1
Database 'Replication_Test' does not exist. Make sure that the name is entered correctly.


Any ideas?
NJ-DBA
NJ-DBA
SSChampion
SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)

Group: General Forum Members
Points: 12438 Visits: 1674
smitty-1088185 (1/3/2012)
I have a database in recovery mode that was part of a mirroring test. I dropped the mirror on the principal and deleted the mirroring endpoints.
The db still exist in the SQL studio manager but when I run, select * from select * from sys.databases it does not exist. The db does show up in the restore db options.


When I right click on the database and click delete it says:
The database 'Replication_Test' is enabled for database mirroring. Database mirroring must be removed before you drop the database. (Microsoft SQL Server, Error: 3743)

I tried to restore the database with recovery and overwrite enabled and it says:
System.Data.SqlClient.SqlError: RESTORE cannot operate on database 'Replication_Test' because it is configured for database mirroring. Use ALTER DATABASE to remove mirroring if you intend to restore the database. (Microsoft.SqlServer.Smo)


So I run the following command "ALTER DATABASE Replication_Test SET PARTNER OFF" and it says:
Msg 911, Level 16, State 1, Line 1
Database 'Replication_Test' does not exist. Make sure that the name is entered correctly.


Any ideas?





Did you disable mirroring on the principle or just on the standby? I think you need to disable both.
johnitech.itech
johnitech.itech
SSCrazy
SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)

Group: General Forum Members
Points: 2942 Visits: 97
[color=#fffffff]Hehe[/color]

Please check the below link

[url=http://msdn.microsoft.com/en-us/library/cc645601.aspx][/url]
smitty-1088185
smitty-1088185
SSCommitted
SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)SSCommitted (2K reputation)

Group: General Forum Members
Points: 1957 Visits: 619
I was able to successfully delete the mirror database but not the principal. I ran a restore with recovery and deleted the endpoints. The database deleted without errors.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum








































































































































































SQLServerCentral


Search