但是在主库执行切换时, alter databae commit to switchover to physical standby with session shutdown;主库和备库都没有产生 19 的归档日志. 这样又如何处理呢?
在主库 alter system switch logfile;传到standby库recover一下,试试看
试过了, 在备库已经有很多新的archive log , 但是恢复时总是要提示缺少日志19 SQL> alter database recover automatic standby database; alter database recover automatic standby database * ERROR at line 1: ORA-00279: change 583222 generated at 12/08/2006 16:48:17 needed for thread 1 ORA-00289: suggestion : C:\ORACLE\PRODUCT\10.2.0\ARCHIVELOG\ARC00019_0608640968.001 ORA-00280: change 583222 for thread 1 is in sequence #37 ORA-00278: log file 'C:\ORACLE\PRODUCT\10.2.0\ARCHIVELOG\ARC00019_0608640968.001' no longer needed for this recovery ORA-00308: cannot open archived log 'C:\ORACLE\PRODUCT\10.2.0\ARCHIVELOG\ARC00019_0608640968.001' ORA-27041: unable to open file OSD-04002: unable to open file O/S-Error: (OS 2) The system cannot find the file specified.
alter system switch logfile;传到standby库recover一下,试试看
试过了, 在备库已经有很多新的archive log , 但是恢复时总是要提示缺少日志19
SQL> alter database recover automatic standby database;
alter database recover automatic standby database
*
ERROR at line 1:
ORA-00279: change 583222 generated at 12/08/2006 16:48:17 needed for thread 1
ORA-00289: suggestion :
C:\ORACLE\PRODUCT\10.2.0\ARCHIVELOG\ARC00019_0608640968.001
ORA-00280: change 583222 for thread 1 is in sequence #37
ORA-00278: log file
'C:\ORACLE\PRODUCT\10.2.0\ARCHIVELOG\ARC00019_0608640968.001' no longer needed
for this recovery
ORA-00308: cannot open archived log
'C:\ORACLE\PRODUCT\10.2.0\ARCHIVELOG\ARC00019_0608640968.001'
ORA-27041: unable to open file
OSD-04002: unable to open file
O/S-Error: (OS 2) The system cannot find the file specified.
查询v$archive_gap:
SQL> select * from v$archive_gap; THREAD# LOW_SEQUENCE# HIGH_SEQUENCE#
---------- ------------- --------------
1 19 19