查看主库状态: select open_mode,protection_mode,database_role,switchover_status from v$database; OPEN_MODE PROTECTION_MODE DATABASE_ROLE SWITCHOVER_STATUS -------------------- ----------------------------- ------------------------ ------------------------ READ WRITE MAXIMUM PERFORMANCE PRIMARY TO STANDBY 查看备库状态: select open_mode,protection_mode,database_role,switchover_status from v$database; OPEN_MODE PROTECTION_MODE DATABASE_ROLE SWITCHOVER_STATUS ------------------------- ----------------------------- ------------------------ ------------------------ READ ONLY WITH APPLY MAXIMUM PERFORMANCE PHYSICAL STANDBY NOT ALLOWED 检查主备两边的序号 select max(sequence#) from v$log; 备库执行,查看是否有数据未应用 select name,SEQUENCE#,APPLIED from v$archived_log order by sequence#; select SEQUENCE#,FIRST_TIME,NEXT_TIME ,APPLIED from v$archived_log order by 1;