标签:start pfile protocol nofile get address touch 检验 rip
准备两台设备,以我的为例一台source ip:192.168.3.66和一台duplicate ip:192.168.3.77
1》基于备份集复制数据库,目录结构都一样(active database网络)
1.在duplicate端检查有没有亚参文件(如果没有的话就创建)
cd $ORACLE_HOME/dbs
touch dummy.ora
编辑vi dummy.ora添加
db_name=‘prod‘
2.在source端复制一个口令文件(前提是在source有orapwprod口令文件,或者自己在duplicate自己创建一个)
scp $ORACLE_HOME/dbs/orapwprod 192.168.3.77:$ORACLE_HOME/dbs
3.检查duplicate必要的文件目录(如果没有创建)
mkdir -p /u01/admin/prod/adump
mkdir -p /u01/flash_recovery_area
mkdir -p /u01/arch/prod
mkdir -p /u01/oracle/dbs
mkdir -p /u01/oradata/prod
4.配置监听器source(可静态可动态)和duplicate(静态):
两端的tns一样如下:
VBOX77 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.3.77)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = prod)
)
)
VBOX66 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.3.66)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = prod)
)
)
5.检查两端的连通性:
两边检查如下
sqlplus sys/oracle@vbox66 as sysdba
sqlplus sys/oracle@vbox77 as sysdba
6.在duplicate端重新登录sys用户sqlplus / as sysdba
SYS@prod>startup pfile=/u01/oracle/dbs/dummy.ora nomount
7.在source端
rman target sys/oracle@vbox66 auxiliary sys/oracle@vbox77
RMAN> duplicate target database to prod from active database spfile nofilenamecheck;
8.完成检验。
标签:start pfile protocol nofile get address touch 检验 rip
原文地址:http://www.cnblogs.com/wjmbk/p/7858146.html