The following opinions expressed in this post are my own and in no way connected to my employer.
Check the current sequence number:
select max(sequence#) from v$log_history;
Use Below Queries to check the gap between primary and standby oracle database:
SELECT ARCH.THREAD# "Thread" ,ARCH.SEQUENCE# "Last Sequence Received",APPL.SEQUENCE# "Lastsequence applied" , (ARCH.SEQUENCE#-APPL.SEQUENCE#) "Difference" FROM (SELECT THREAD# ,SEQUENCE# FROM V$ARCHIVED_LOG WHERE (THREAD#,FIRST_TIME ) IN (SELECT THREAD#,MAX(FIRST_TIME) FROM V$ARCHIVED_LOG GROUP BY THREAD#)) ARCH, (SELECT THREAD# ,SEQUENCE# FROM V$LOG_HISTORY WHERE (THREAD#,FIRST_TIME ) IN (SELECT THREAD#,MAX(FIRST_TIME) FROM V$LOG_HISTORY GROUP BY THREAD#)) APPL WHERE ARCH.THREAD# = APPL.THREAD# ORDER BY 1;
SELECT THREAD#, LOW_SEQUENCE#, HIGH_SEQUENCE# FROM V$ARCHIVE_GAP;
Use Below to cancel Redo Log Apply:
ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;
Use Below to enable Redo Log Apply:
ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROM SESSION;
Commentaires