Database migration approaches
-
Backup and Restore:
- Take a backup/export of source database to a file/folder
- Move the backup to destination
- Restore/import the backup into destination db
- Advantages:
- Simple
- Disadvantage:
- Downtime will be required if the source database is changing
- Downtime will be required if the source database is changing
-
Replicate or Synchronize Databases:
- Create a Replica of the source database
- Once the replication is complete
- Failover to the destination database
- Advantage:
- Less Downtime (in minutes)
- Disadvantage:
- DBA skills to perform
- Replication adds performance overhead to the source
-
Migration from different database engine
Database Migrations in AWS
- AWS has a service DMS which is designed to migrate
- From any source (onpremise/cloud) to any destination (onpremise/cloud)
- from some database engines to some other databases