原来在主备库上发现日志应用存在异常时,都是通过拷贝的方式将归档日志从主库传到备库,然后注册应用
在备库通过RMAN来获取归档日志更加简单
1.在主库确认归档序号
select NAME,DEST_ID,THREAD#,SEQUENCE#,COMPLETION_TIME,REGISTRAR,APPLIED,DELETED from v$ARCHIVED_LOG where SEQUENCE# between 44561 and 44566 and THREAD#=1 and DEST_ID=1;
2.在备库执行获取归档命令
rman target sys/oracle@primary auxiliary sys/oracle@standby
backup as copy archivelog sequence between 44561 and 44566 thread 1 auxiliary format '+DATA';
backup as copy archivelog sequence between 44159 and 44160 thread 2 auxiliary format '+DATA';
3.在备库注册归档,少量使用alter命令;多量使用catalog命令。
alter database register physical logfile '归档路径';
catalog start with '+DATA/dghxa/archivelog/';
|