September 12, 2015 at 2:07 am
Hi
We have 2 switch between primary and secondary this morning.
after that one database in secondary went to "initializing / recovery pending".
How can i exit from this situation ?
Thank you
September 12, 2015 at 3:16 am
Most likely it is still in recovery rolling forward the entries from t log..
run the following query and pay attention to the columns last_redo_time,last_harden_time, suspend_reason_desc
select replica_server_name as servername,db_name(database_id) as database_name,
is_local,cs.is_failover_ready,
synchronization_health_desc,database_state_desc,last_sent_time,last_received_time,
last_hardened_time,last_redone_time,log_send_queue_size,log_send_rate,redo_queue_size,
redo_rate,end_of_log_lsn,last_commit_time,last_commit_lsn,low_water_mark_for_ghosts ,
is_suspended,suspend_reason_desc,rep_state.recovery_lsn,
rep_state.truncation_lsn,last_sent_lsn,last_received_lsn,last_hardened_lsn,last_redone_lsn
from
sys.dm_hadr_database_replica_states rep_state,sys.availability_replicas ar,
sys.dm_hadr_database_replica_cluster_states as cs
where rep_state.replica_id=ar.replica_id
and rep_state.group_id = ar.group_id
and cs.replica_id = ar.replica_id
and cs.group_database_id = rep_state.group_database_id
btw, are u on sync or async mode?
Regards,
Raj
September 12, 2015 at 3:30 am
Unfortunately we were on emergent status.
then we
1- change all IP Config from Listener to Direct Primary
2- From Primary I removed that database from AG.
3- From secondary I Drop That Database
4- From Primary I Add That database to AG Again.
I know that is not correct way to recovery that database.
And know I will be very Pleasant that you say me about that. (continue to correct from your solution)
and we have syn. mode.
thank you
September 12, 2015 at 4:17 am
May I know why opted for such a method... was that because it was on recovery pending after always on failover?
Was it just one db on always on group that had such a issue? Did management studio report the failover to be successful without any warnings?
Regards,
Raj
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply