Availability Group database Restore fails - by Sajive

Status : 

  By Design<br /><br />
		The product team believes this item works according to its intended design.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 650591 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 3/10/2011 4:05:15 AM
Access Restriction Public


1. Backup the primary instance database belonging to Availability Group
2. Restore the backed up primary instance database on the primary instance.

We get the error

System.Data.SqlClient.SqlError: RESTORE cannot operate on database 'AG_DENALI' because it is configured for database mirroring or has joined an HADR Availability Group. Use ALTER DATABASE to remove mirroring or to unjoin from its Availability Group if you intend to restore the database. (Microsoft.SqlServer.Smo)

We are unable to get the query (ALTER DATABASE) to remove mirroring or to unjoin from its availability group.  
Sign in to post a comment.
Posted by Sajive on 3/10/2011 at 9:15 PM
Can you please let us know when will Denali CTP2 and RTM be available.
Posted by Microsoft on 3/10/2011 at 5:52 PM
Thnaks for taking the time to use CTP1. This will be part of the ALTER AVAILABILITY GROUP syntax not yet available in CTP1. Before RTM there will be functionality to remove a DB from an availability group.

The limitations for AlwaysOn in CTP1 are documented in the release notes Section 3.7.1: http://social.technet.microsoft.com/wiki/contents/articles/sql-server-code-named-quot-denali-quot-ctp1-release-notes.aspx#DatabaseEngine

Please let us know if you have further questions.