Precise Instantiation for Oracle Using the RMAN Method

The following steps are required to set up the RMAN instantiation for Oracle database while using Oracle GoldenGate.
  1. Install and set up Oracle GoldenGate by deploying the software on both the source and target systems. Before configuring anything, make sure all database prerequisites are met. This includes enabling minimal supplemental logging on the source database, and using ADD TRANDATA or ADD SCHEMATRANDATA to ensure key columns in the replicated tables are logged.

  2. Add and configure the Extract and DISTPATH processes on the source database.

  3. Add and configure the Replicat process on the target database.

  4. Start the Extract process and make sure that Extract starts running before any long-running transactions begin because Extract only captures complete transactions.
  5. Start the DISTPATH process.

  6. Do not start the Replicat process. wait until the target database has been fully recovered.

  7. Use RMAN to take a backup of the source database. This backup will be used later to create the target database. The backup files need to be securely transferred to the target system.
    RMAN target /
    RMAN> BACKUP DATABASE PLUS ARCHIVELOG
  8. Use RMAN to create a duplicate of the source database and rename it as the target database name. For example, if the target database name is DBSOUTH, then rename the duplicate of the source database as DBSOUTH. Make sure to note the SCN (System Change Number) value during this process, as it marks the exact point in time where both databases are in sync. The following example displays the creation of a duplicate of the DBNORTH database, which is named as DBSOUTH (same as the target database).
    OS> RMAN target /
    
    RMAN> restore database preview summary
    >>> Recovery must be done beyond SCN 1420004711 to clear datafile fuzziness
    
    OS> target sys/tiger99_RR@dbnorth
    
    RMAN> connect auxiliary
    RMAN> duplicate target database to DBSOUTH nofilenamecheck until SCN 1420004711;
  9. Start the Replicat process on the DBSOUTH database, making sure it starts exactly at the same SCN as the database that was recovered using RMAN.

    Use the ATSCN option to ensure there is no data gap during replication:

    OGG http://www.example.com:12000 depl_south> START REPLICAT REPS, ATCSN 1420004711 

The following diagram illustrates these steps:
Instantiating the target database using RMAN while continuing replication on source database using Oracle GoldenGate Extract