One of the most exciting services offer by AWS is the Database Migration Service (DMS). This service helps you rapidly move your on-prem databases into the cloud with minimal effort and downtime.
Most companies have many relational databases that they'd like to move to the cloud and this service makes it simple to do so.
An additional benefit to migration to the cloud for databases is to take advantage of the improved security and reduced operational costs of AWS Relation Database Service (RDS). AWS RDS is a managed service for popular databases like PostgreSQL, Microsoft SQL Server, and Oracle and you can select it as your target database (as seen above).
The following are the high level steps it takes to complete a migration using DMS:
1. Configure Source Database
- Network configuration needs to be in place to allow connectivity with AWS DMS
2. Configure the target database
- Configure & create the RDS instance to be used base on your needs
- DB permission (if needed)
- Networking configurations on Target Database to allow connectivity with AWS DMS
3. Create a AWS DMS Replication Instance
- Define VPC, subnet group and AZ and your VPC security groups (e.g. to specify inbound and outbound network access to replication instance)
4. Create a DMS Source Endpoint
- Define Source Engine (Type of Db engine endpoint will be connected to, We can specify if source is RDS or not)
- Test Endpoint connection (Important :This step test connectivity between your AWS DMS replication instance and your source Db endpoint information)
5. Create a DMS Target Endpoint
- Define target database engine
- Input all the database details (e.g. server endpoint, port, username, password, SSL mode)
- Test endpoint connection (Important :This step test connectivity between your AWS DMS replication instance and your Target Db endpoint information)
6. Create a DMS Migration Task
- Define replication instance
- Define the source database endpoint
- Define the target database endpoint
7. Choose a Migration Type
Here you need to choose the following type of migration you want to perform:
- Migrate existing data (Full Load)
- Migrate existing data and replicate ongoing changes
- Replicate data changes only
8. Create Tasks Settings
- Choose to drop tables on target, truncate or do nothing
- Choose to Include LOB Columns in replication or not
- Enable Validation (To compare data at the source and the target )
- Enable Cloudwatch logs
9. Setup Table Mappings
Choose the schema and/or tables to include or exclude from the migration tasks. This can be done using the UI or with a JSON file.
10. Run the Migration
That's it. Now all that is left is to execute the migration and enjoy the benefits of having your relational database on the cloud.
How Long Does it Take?
Xerris has used the DMS tool effectively with numerous clients including moving an oracle database to AWS in just 8 weeks. The process can vary, depending on if you need to upgrade your schema, validate your data, and perform a live-migration with an active database using the Change Data Capture (CDC) feature of the service. In general it should be between 4-8 weeks from start to finish.
Depending on your source and target database there are individual guides that AWS provides that can help you get familiar with the whole process.
Another option is to engage an AWS partner like Xerris to assist in the migration process. Xerris and AWS use a process called the Migration Assistance Program that helps take you every step of the way and helps you get on the cloud as quickly as possible.