环境:

OS:Centos 7

DB:11.2.0.4

 

1.主从切换后发现,新的主库的状态是RESOLVABLE GAP

SQL> select switchover_status from v$database;

SWITCHOVER_STATUS

--------------------

RESOLVABLE GAP

2.检查下数据库的参数

*.log_archive_dest_1='location=/u01/app/oracle/archive_log/ valid_for=(all_logfiles,all_roles) db_unique_name=slavea'

*.log_archive_dest_2='service=tnsslnngk async valid_for=(online_logfiles,primary_role) db_unique_name=slnngk'

*.log_archive_dest_3='service=tnsslaveb async valid_for=(standby_logfiles,standby_role) db_unique_name=slaveb'

log_archive_dest_3是指向另外的一个备库,之前dataguard环境是级联的,将目前不需要该参数,将该参数去掉问题解决.

SQL> alter system set log_archive_dest_3='' scope=both;

System altered.

SQL> select switchover_status from v$database;

SWITCHOVER_STATUS

--------------------

TO STANDBY