Oracle Cloud Infrastructure Database Migration (DMS) enables you to migrate data from an Oracle Database Cloud Service (DBCS) instance to another DBCS instance located in a different region. Oracle Cloud Infrastructure Database Migration is a fully-managed service that provides a high-performing, self-service experience for migrating databases from On-Premise to Oracle Cloud Infrastructure (OCI) and for migrating databases across regions. It provides logical online and offline migration for enterprise-level database migration with minimal downtime. Oracle Cloud Infrastructure Database Migration is based on the industry-leading Oracle Zero Downtime Migration engine utilizing Oracle GoldenGate replication

In this blog post, we’ll go through the steps to migrate an existing Oracle Database running on VM DB System to an existing Oracle Database running on VM DB System in another region. We’ll use Oracle Cloud Infrastructure Database Migration (DMS) to migrate the database from one region to another.

To enable data transfer between two regions we need to connect both source and target VCNs where the databases reside via remote VCN peering. Remote VCN peering is the process of connecting two VCNs in different regions (but in the same tenancy ). The peering allows the VCNs’ resources to communicate using private IP addresses without routing the traffic over the internet or through your on-premises network. Without peering, a given VCN would need an internet gateway and public IP addresses for the instances that need to communicate with another VCN in a different region. Refer to the documentation for setting up Remote Peering between the two VCNs.

Oracle Cloud Infrastructure Database Migration (DMS) can be used for both Online and Offline Migration. Oracle GoldenGate replication enables you to perform an online migration with Oracle Cloud Infrastructure Database Migration. In this blog post we will be performing Offline Migration using Oracle Data Pump.

Steps already completed for this migration :

1.    Source Database running on Oracle Base Database Service in Phoenix Region.
2.    Target Database running on Oracle Base Database Service in Ashburn Region.
3.    Remote peering setup between the two regions.

Points to consider before configuring Oracle Cloud Infrastructure Database Migration (DMS) :

1.    Register the Source Database in DMS by manually configuring the database. Do not register by selecting the DBCS instances listed. 
2.    The Target Database must be in the same region as DMS.
3.    Databases configured manually cannot be used as target databases in migrations.
4.    If the source database is a multitenant container database (CDB), and you are performing an online migration, you must create two registration entries for the source database: one for the PDB and one for the CDB. For offline migrations, only the PDB registration is required.
5.    Create only one registered database resource for the target database.

Migration Steps :

1.    Oracle Base Database Service Source database provisioned in Phoenix Region

Source DB

2.    Oracle Base Database Service Target database provisioned in Ashburn Region

Target DB

3.    Launch DMS service in Target Database region – Ashburn – to register databases.
DMS

4.    Register Source Database

Register Source CDB by manually configuring the database. Specify the Database VM Host IP address and CDB Service name to configure the database. As, the databases are in a private subnet, select the subnet for private endpoint. Specify the private subnet from the VCN that has been peered. Enter the Database credentials to connect to the database and click on Register to register the database.

Source CDB     Source CDB  

Similarly, register Source PDB by manually configuring the database. Specify the Database VM Host IP address and PDB Service name to configure the database. 

Source PDB     Source PDB
5.    Register Target Database

Register the target database by selecting the database rather than manually configuring it. Select the “Database Type” as “DB system database (Bare Metal, VM, Exadata)” and then select the source database provisioned in Ashburn region. When specifying the “Connect String” ensure that the string contains an IP address for the host, and if needed change the FQDN to an IP address.

Target DB     Target DB     

6.    Create Migration in DMS

Create a Migration in DMS, by entering the Name of the Migration and details of the Vault and Key.

Migration

Select the Source and Target Database :
Migration

Select the Object Storage Bucket which will be used to upload the export dump files from Source Database and will then be used by the Target Database for importing the dump files. Also, specify the Export and Import Directory Objects. These Directory objects will be created by the migration in respective databases.

Migration

7.    Run Validate Migration

First “Validate” the Migration and ensure all the Phases have Completed Successfully. The “Validate” job has following phases :

1.    Validate target    
2.    Validate source    
3.    Validate premigration advisor    
4.    Validate datapump source settings    
5.    Validate datapump target settings

Validate DMS

8.    Once “Validate” has completed successfully click on “Start” to start the Migration Job. Verify that all phases of Migration job have completed successfully.
Start DMS

Once the migration has completed, login to the target database and verify that the data has been migrated successfully from source to target database.

Conclusion

Oracle Cloud Infrastructure Database Migration is a fully-managed service that provides you a high performing, self-service experience for migrating databases to Oracle Cloud Infrastructure (OCI). Using OCI DMS, one can also migrate databases from one OCI region to another OCI region. Remote VCN Peering is used to connect VCN from different regions in which the databases are provisioned.