Tuesday, May 13, 2014

Alwayson replica is showing database in Synchronizing state only


On AlwaysOn High availability if database is showing Synchronizing for a while, then the below steps may helps you to fix the issue, I observed if t-log is not applied on secondary replica then we may see that error.

From Secondary Replica

1. Verify the secondary database is in Synchronizing state or not if it is in synchronizing state move to 2nd step

2. AlwaysOnHigh Availability -- Availability Groups -- Availability Databases

3.  Right click on the database which is not in sync -- Remove Secondary Database - OK

4. Now the database will not completely remove from the Availabililty Databases, If you right click
on it, it shows Join Availability group
5. SSMS - Database -- Check the problematic database should come from Synchronizing state to
restoring state

6. Now Right click on database - Tasks - Restore - Transaction Log

7. Verify what is the last transaction log backup restored on this database from "select the transaction
log backups to restore" window
8. We need to restore the remaining backups after last backup to latest transaction log manually
9. Make sure you should select NoRecovery option till last transaction log backup restores

10. After completion of all T-Log backups the database status should display Restoring
11. AlwaysOnHigh Availability -- Availability Groups -- Availability Databases
12. Right click on database which you are working on -- Join Availability Group -- OK
13. Right click on database - Refresh (It should display green sync icon)
14. Verify the Alwayson Dashboard -- Now the database will be in sync

 

No comments: