Migrate the Database

Create a backup of the source database, then transfer the backup from the source to the cloud.

Perform an RMAN Backup of the Source Database

Perform an Oracle Recovery Manager (RMAN) backup of the source database for the Oracle GoldenGate initial load.

The method of migration depends on the database size, the complexity of the migration, and your organization requirements. This example uses an RMAN backup of source database for the initial load of the target database on cloud and the database backup can be taken directly on Oracle Cloud Infrastructure Object Storage using RMAN.

If you prefer to not configure libraries to perform a backup on your database server or if you have a bandwidth limitation for direct transfer to object storage, then you can take the backups locally and move them directly to the Oracle Database Exadata Cloud Service node.

An important factor to consider for RMAN backup is the number of channels to be used. The more channels, the faster the backup. The number of channels are limited by the performance of the underlying I/O subsystem. A good practice is to run a few backup tests to arrive at the optimum number of channels that will provide maximum speed for available I/O subsystem.

Backup compression also plays an important role. The smaller the size of compressed backup, the less time to transfer the backup pieces to cloud over Oracle Cloud Infrastructure FastConnect. The compression ratio that can be achieved for backup depends on underlying data in database but it is always good to use compression to reduce the size of backup pieces.

If you have restrictions to execute backup for migration on the production system, then you can take the backup from a standby database.

  1. Create a backup of your database using the number of channels and compression ratio that are optimal for your database.
    $ cat /home/oracle/backup.sh
    #!/bin/ksh
    export ORACLE_SID=bildb
    rman target / msglog /home/oracle/backup.log cmdfile=/home/oracle/backup.rcv
    $ cat /home/oracle/backup.rcv
    run
    {
    allocate channel ch1 type DISK ;
    allocate channel ch24 type DISK ;
    BACKUP AS COMPRESSED BACKUPSET DATABASE FORMAT '/rman_backups/bildb/%d_D_%T_%u_s%s_p%p'
    plus archivelog format '/rman_backups/bildb/arch_%U';
    BACKUP CURRENT CONTROLFILE FORMAT '/rman_backups/bildb/cntrl_%s_%p_%t';
    release channel ch1;
    release channel ch24;
    }
    $ nohup sh /home/oracle/backup.sh &
    
  2. Run the restore database preview summary command.
    RMAN> restore database preview summary
    The summary includes the SCN number of the RMAN backup. Record and save the SCN number. This is the SCN up to which data will be restored on target for the Oracle GoldenGate initial load and will be the starting point for the change synchronization on the target database.

Transfer the Backup from the Source to the Cloud

Create an Oracle ASM Cluster File System (Oracle ACFS) to hold the temporary backups for restore, then transfer the backup to the Oracle Database Exadata Cloud Service database server.

Oracle Database Exadata Cloud Service has limited space on local filesystems. To ensure that you have sufficient space for restore, create an Oracle ACFS filesystem to hold the temporary backups.

  1. Create an Oracle ACFS filesystem on the RECO diskgroup to store the temporary backups for restore.
    Creating the filesystem on the RECO diskgroup ensures that the DATA diskgroup has sufficient space available for restore.
  2. Use SCP/WinSCP to transfer the backup directly to the Oracle Database Exadata Cloud Service database server.