RMAN-05535 AND ORA-00312

在通过duplicate 命令创建physical standby库时,遇到这个问题:


[oracle@beijing dbs]$ rman target / auxiliary sys/oracle@prodx


Recovery Manager: Release 11.2.0.3.0 - Production on Wed Sep 4 01:20:10 2013


Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.


connected to target database: PROD (DBID=237046118)
connected to auxiliary database: PROD (not mounted)


RMAN> duplicate target database
2> for standby
3> from active database
4> DORECOVER nofilenamecheck
5> spfile
6> set db_unique_name='prodx'
7> set log_archive_dest_1='location=/arch142 VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=prodx'
8> set log_archive_dest_2='SERVICE=prodb ASYNC LGWR VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=prodb'
9> set standby_file_management='AUTO'
10> set fal_server='prodb'
11> set fal_client='prodx'
12> set control_files='/oradata/prod/control01.ctl'
13> set memory_target='0'
14> set sga_target='600M';


Starting Duplicate Db at 04-SEP-13
using target database control file instead of recovery catalog
allocated channel: ORA_AUX_DISK_1
channel ORA_AUX_DISK_1: SID=10 device type=DISK

..........................省略部分..............................

starting media recovery


archived log for thread 1 with sequence 7 is already on disk as file /arch142/arch_825207784_1_7.arc
archived log for thread 1 with sequence 8 is already on disk as file /arch142/arch_825207784_1_8.arc
archived log file name=/arch142/arch_825207784_1_7.arc thread=1 sequence=7
archived log file name=/arch142/arch_825207784_1_8.arc thread=1 sequence=8
media recovery complete, elapsed time: 00:00:00
Finished recover at 04-SEP-13
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 1 thread 1: '/oradata/prod/redo01.log'


RMAN-05535: WARNING: All redo log files were not defined properly.
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 2 thread 1: '/oradata/prod/redo02.log'


RMAN-05535: WARNING: All redo log files were not defined properly.
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 3 thread 1: '/oradata/prod/redo03.log'


RMAN-05535: WARNING: All redo log files were not defined properly.
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 4 thread 0: '/oradata/prod/std_redo04.log'


RMAN-05535: WARNING: All redo log files were not defined properly.
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 5 thread 0: '/oradata/prod/std_redo05.log'


RMAN-05535: WARNING: All redo log files were not defined properly.
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 6 thread 0: '/oradata/prod/std_redo06.log'


RMAN-05535: WARNING: All redo log files were not defined properly.
ORACLE error from auxiliary database: ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 7 thread 0: '/oradata/prod/std_redo07.log'


RMAN-05535: WARNING: All redo log files were not defined properly.

Finished Duplicate Db at 04-SEP-13


起初我认为2端的目录是完全一样的,不用加log_file_name_convert参数进行转换制定,查询文档后发现,即使2端的文件名和目录是一致的,也需要加上log_file_name_convert参数,即:加上:

log_file_name_convert='/oradata/prod','/oradata/prod'


修改后的duplicate命令见下:


duplicate target database
for standby
from active database
DORECOVER nofilenamecheck
spfile
set db_unique_name='prodx'
set log_archive_dest_1='location=/arch142 VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=prodx'
set log_archive_dest_2='SERVICE=prodb ASYNC LGWR VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=prodb'
set standby_file_management='AUTO'
set fal_server='prodb'
set fal_client='prodx'
set control_files='/oradata/prod/control01.ctl'
set log_file_name_convert='/oradata/prod','/oradata/prod'
set memory_target='0'
set sga_target='600M';

你可能感兴趣的:(Duplicate,&,Auxiliary)