*copy passwd file from primary
scp $ORACLE_HOME/dbs/passwd$ORACLE_SID{instance_number}
cp [pwd file from primary] orapw$ORACLE_SID
*create static listener
SID_LIST_LISTENER = (SID_LIST = (SID_DESC = (GLOBAL_DBNAME = u41testdb.rt.ru) (ORACLE_HOME = /oracle/app/base/db/12.1.0.2) (SID_NAME = s41testdb) ) )
create audit directory:
mkdir -p /oracle/app/base/admin/s41testdb
create asm directory:
ASMCMD [+] > mkdir +DATA/u41testdb
*startup dummy instance:
echo db_name='db_name' > pfile.ora startup nomount pfile='pfile.ora'
*connect auxiliary instance +connect target instance
rman target sys/xxxxx@u41testdb auxiliary sys/xxxxx@s41testdb RMAN> duplicate target database for standby from active database spfile set "db_unique_name"="s41testdb" set "cluster_database"="false" set "audit_file_dest"="/oracle/app/base/admin/s41testdb";
DGMGRL> create configuration u41dg as primary database is u41testdb connect identifier is u41testdb ; Configuration "u41dg" created with primary database "u41testdb" DGMGRL> add database s41testdb as connect identifier is s41testdb maintained as physical; Database "s41testdb" added DGMGRL> enable configuration; Enabled. DGMGRL>
1 комментарий
run {
allocate channel prmy1 type disk rate 50m;
allocate auxiliary channel stby type disk rate 50m;
duplicate target database for standby from active database
spfile
set «DB_UNIQUE_NAME»=»P00TEST»
set «audit_file_dest»=»/oracle/app/base/admin/p00TEST/audmp»
set «db_file_name_convert»=»+DATA/S00TEST/»,»+DATA/P00TEST/», «+REDO/S00TEST/»,»+REDO/P00TEST/»
set «log_file_name_convert»=»+DATA/S00TEST/»,»+DATA/P00TEST/», «+REDO/S00TEST/»,»+REDO/P00TEST/»
set «use_large_pages»=»false»;
}