We will use the AWS Database Migration Service to perform the migration securely and quickly. The Source database remains intact and operational during the migration process, so the applications that rely on the original database will not be affected.
During the migration, DMS manages all the complexities of the migration process, such as automatically replicating data changes that occur in the source database during the migration process.
AWS Database Migration Service is a reliable, highly resilient, and self–healing service. Continually monitors source and target databases, network connectivity, and the replication instance. In case of interruption, it automatically restarts the process and continues the migration from where it stopped.
AWS Database Migration Service offers simplified functionality. No need to install any drivers or applications; in most cases, it does not require changes to the source database.
We will create an Oracle database and tables in it as a source database.
Then Create an Aurora MySQL database as the target for the migration.
Finally, we will use the Database migration wizard to perform such migration.
Let us create the Source Oracle Database
Since this is a POC, we use Dev/Test.
Target MySQL Database
Since this is a POC, we use Dev/Test.
We have Source, and Target Databases created.
Now we connect to the Source DB endpoint.
Now we are connected to the source Database using Oracle SQL Developer.
We go to the worksheet editor and enter a SQL statement.
This will be the table we are about to migrate to MySQL using the Database Migration Service.
CREATE TABLE sample
(
sample_id NUMBER(10) NOT NULL,
sample_name varchar2(50) NOT NULL,
sample_qty varchar2(50)
);
Now on the Database migration service, we create a replication instance
Add a name for the replication instance.
Create a Database migration service source endpoint.
Since it is the source, we select Oracle as the source engine.
Now we test the endpoint connection.
Click on create endpoint and select Target endpoint.
Then chose Aurora MySQL as the target engine.
Now we have the Source and Target Endpoints
We now create a Database migration task.
The database migration task runs; now it says Load complete and 100% progress.
Now we connect to the target endpoint using MySQL Workbench.
Let’s test the connection to the database
We can see the SAMPLE table was successfully migrated under the ADMIN schema.
We could migrate a database with almost no effort and zero downtime.
Data changes to the source database during the migration are continuously replicated to the target, allowing the source database to be fully operational during the migration process.
AWS Database Migration Service supports homogeneous migrations, such as Oracle to Oracle, and heterogeneous migrations between different database platforms, such as Oracle or Microsoft SQL Server to Amazon Aurora.
AWS Database Migration Service is relatively low-cost since you only pay for the compute resources used during the migration process and any additional log storage. Migrating a terabyte-size database can be done for as little as $3 for homogeneous and heterogeneous migrations of any supported databases.