Prepare two devices, take my example a source ip:192.168.3.66 and a duplicate ip:192.168.3.77
1 "Copy the database based on the backup set, the directory structure is the same (Active database network)
1. Check the duplicate to see if there are any parameter files (if not, create them)
CD $ORACLE _home/dbs
Touch Dummy.ora
Edit VI Dummy.ora Add
Db_name= ' prod '
2. Copy a password file on the source side (provided the source has a Orapwprod password file, or you create one yourself in duplicate)
SCP $ORACLE _home/dbs/orapwprod 192.168.3.77: $ORACLE _home/dbs
3. Check the duplicate necessary files directory (if not created)
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. Configure Listener source (static and dynamic) and duplicate (static):
The two ends of TNS are as follows:
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. Check the connectivity of both ends:
Check both sides as follows
Sqlplus Sys/[email protected] as Sysdba
Sqlplus Sys/[email protected] as Sysdba
6. Re-login to sys user sqlplus/as on the duplicate side SYSDBA
[Email protected]>startup Pfile=/u01/oracle/dbs/dummy.ora Nomount
7. On the source side
Rman target Sys/[email protected] auxiliary sys/[email protected]
Rman> Duplicate target database to prod from active database SPFile Nofilenamecheck;
8. Complete the inspection.
Oracle Replication Database