AWS DMS copies data and can apply ongoing changes to support a controlled cutover.
Schema conversion
When a database moves to a different engine, such as Oracle to Amazon Aurora PostgreSQL, its schemaA database schema defines database objects such as tables, views and functions. has to be converted before the data can follow. That conversion covers tables, views and code. AWS SCT and DMS Schema Conversion do it; AWS DMS moves the data.
How it works
- Create a migration project with source and target databases.
- Convert the schema for the target database.
- Migrate the data with AWS DMS, with change data captureChange data capture reads ongoing changes from a source data store so they can be replicated. if the source stays live.
| Migration | Schema step | Data step |
|---|---|---|
| Same engine (homogeneous), such as MySQL to Amazon RDS for MySQL | Usually none | AWS DMS |
| Different engine (heterogeneous), such as Oracle to Aurora PostgreSQL | AWS SCT or DMS Schema Conversion | AWS DMS |
Exam cues
- If the question says change database engines, think schema conversion first, then AWS DMS for the data.
Remember
- Schema conversion converts structure and code, not data.
- Targets include Amazon RDS engines, Aurora and Redshift.
Trap: AWS DMS alone does not rewrite an Oracle schema for PostgreSQL. A heterogeneous migration needs schema conversion too.
Da documentação da AWS (4)
- The AWS Schema Conversion Tool (AWS SCT) converts an existing database schema from one database engine to another, for OLTP or data warehouse schemas.
- AWS SCT output suits Amazon RDS for MySQL, MariaDB, Oracle, SQL Server and PostgreSQL, Amazon Aurora and Amazon Redshift, and can also be used with a database on Amazon EC2.
- DMS Schema Conversion is a feature of AWS DMS that converts source schemas to a format compatible with Aurora, Amazon RDS or Amazon Redshift.
- DMS Schema Conversion converts the database schema, not the data; data migration uses the data migration features of AWS DMS.
Full load and change data capture
AWS Database Migration Service (DMS) moves data between supported data stores and can keep a target updated while the source changes. Think of a full loadA full load copies existing source data to a target. as the initial copy and change data captureChange data capture reads ongoing changes from a source data store so they can be replicated. (CDC) as the stream of later changes.
How it works
- Use source and target endpointsA DMS endpoint holds connection, type and location information for a data store.. At least one endpoint must be an AWS service.
- Select a replication instanceA DMS replication instance reads data from the source and loads it into the target., which reads and loads data, or use DMS Serverless to provision and scale capacity automatically. Multi-AZ gives a provisioned instance a synchronous standby in another Availability Zone.
- Choose the task type. Full load plus CDC copies existing data while caching changes for each table once its load starts, applies those changes, then continues replication from source logs. Configure the source for CDC as required by its engine.
- After replication reaches a steady state, stop the application, allow remaining changes to reach the target, and restart the application against the target.
| Task | Use |
|---|---|
| Full load only | Copy existing data, including views when needed. |
| Full load plus CDC | Copy existing data and continue applying changes. |
| CDC only | Replicate changes after the target already has its initial data. |
Exam cues
- If the question says reduce migration cutover downtime, think full load plus CDC, because ongoing changes are applied after the initial copy.
- If the question says automatic failover of a provisioned DMS instance, think Multi-AZ, because it maintains a synchronous standby.
- If the question says the target already has its initial data, think CDC only, because the task replicates ongoing changes.
- If the question says replication capacity should scale without instance management, think DMS Serverless.
- If the question says a MongoDB-compatible database, think Amazon DocumentDB. If it says a data warehouse for large analytical queries, think Amazon Redshift. Redshift omits some features suited to small transactions, such as efficient single-row data manipulation. DMS moves data rather than serving as the destination database.
Remember
- CDC is not real time and has no latency SLA. Latency is the delay in applying changes.
- Use a full-load-only task to migrate views.
Trap: CDC is not real time and has no latency SLA. Use a full-load-only task when the migration must include views.
DMS reads source data and captures changes.
DMS loads the target and applies captured changes.
Da documentação da AWS (18)
- AWS DMS migrates data between supported data stores and can replicate ongoing changes.
- At least one endpoint must be on an AWS service; DMS cannot migrate between two on-premises databases.
- DMS supports full-load-only tasks, full load plus ongoing replication and ongoing-replication-only tasks.
- A full load plus CDC task loads existing data, applies cached changes and then applies ongoing changes as transactions.
- During full load DMS starts capturing changes for a table when that table's full load starts and applies cached changes after its load completes.
- CDC reads ongoing changes from source database logs using engine-specific methods; source configuration requirements vary by engine.
- DMS CDC is not real-time replication and has no latency SLA.
- After replication reaches steady state, applications can be stopped while remaining changes are applied and restarted against the target.
- DMS Schema Conversion assesses and converts schemas and code for a different target engine; objects it cannot convert automatically require manual conversion.
- Amazon DocumentDB is a managed database service for MongoDB-compatible databases.
- Amazon Redshift is a managed data warehouse service for analyzing data.
- Amazon Redshift is designed for analytical queries over large datasets and omits some features suited to transactional processing, including efficient single-row data manipulation.
- A Multi-AZ DMS replication instance has a synchronous standby in a different Availability Zone for availability and failover.
- DMS Serverless automatically provisions and scales replication capacity and provides built-in high availability.
- CDCLatencySource measures the delay between the source and the replication instance.
- High CDCLatencyTarget indicates a delay applying change events to the target.
- FreeableMemory includes memory in buffers and cache that can be freed and is not the same as actual free memory.
- Views can be migrated with full-load-only tasks but not with tasks that include CDC.
Schema and endpoint choices
AWS Database Migration Service (AWS DMS) offers schemaA database schema defines database objects such as tables, views and functions. conversion and endpointA DMS endpoint holds connection, type and location information for a data store. options for different migration needs. A schema describes the structure of a database; converting it helps when the target uses a different engine.
How it works
- For a different target engine, use DMS Schema Conversion or AWS Schema Conversion Tool to convert the source schema. With DMS Schema Conversion, run an assessment to see which objects need manual work.
- Convert the schema and code, manually handle objects that cannot be converted automatically, then apply the converted code to the target or export it as SQL scripts.
- Choose source and target endpoints for the data. For example, DMS can read CSV or Parquet files from Amazon S3 for a full loadA full load copies existing source data to a target. and new files for ongoing changes, with Amazon Kinesis Data Streams as the target.
- To encrypt a source or target endpoint connection with SSL, assign a certificate to the endpoint, such as an imported certificate authority (CA) certificate.
Exam cues
- If the question says estimate manual schema conversion work, think DMS Schema Conversion assessment, because it shows what converts automatically and what needs manual work.
- If the question says load S3 files and ongoing changes into a stream, think S3 source and Kinesis Data Streams target, because DMS supports both endpoints.
- If the question says move MongoDB data to Amazon DynamoDB, think DMS, because DynamoDB can be a target for a MongoDB or relational source.
- If the question says encrypt a database endpoint connection, think SSL and a certificate assigned to the endpoint.
Remember
- AWS Schema Conversion Tool is an alternative to DMS Schema Conversion.
- An assessment identifies conversion work that needs manual attention.
Trap: Schema conversion does not automatically handle every object. Review the assessment and convert unsupported objects manually.
Da documentação da AWS (7)
- DMS Schema Conversion assesses and converts schemas and code for a different target engine; objects it cannot convert automatically require manual conversion.
- AWS Schema Conversion Tool is an alternative to DMS Schema Conversion for converting source schemas.
- AWS DMS can use Amazon S3 as a source, reading CSV or Parquet files for a full load and new files for ongoing changes.
- AWS DMS can use Amazon Kinesis Data Streams as a target.
- AWS DMS can encrypt source and target endpoint connections with SSL by assigning a certificate, such as an imported certificate authority (CA) certificate, to the endpoint.
- AWS DMS can migrate data into a DynamoDB table, with a relational database or MongoDB as the source.
- DMS Schema Conversion can run an assessment showing what converts automatically and what needs manual work, then apply the converted code to the target or export it as SQL scripts.
Flashcards
Nada para revisar aqui agora. Escolha outros tópicos ou outro filtro.
·
Todos os 14 flashcards em lista
A company is migrating an Oracle database to Amazon Aurora PostgreSQL. Which AWS tools convert the schema?
AWS Schema Conversion Tool (AWS SCT) or DMS Schema Conversion. AWS DMS then migrates the data.
Does AWS Schema Conversion Tool also copy the data to the new database engine?
No. Schema conversion converts the schema; AWS DMS migrates the data.
How do Amazon DocumentDB, Amazon Redshift and AWS DMS differ?
DocumentDB runs MongoDB-compatible databases. Redshift is a data warehouse for analytics. DMS migrates data and can replicate ongoing changes.
A team must migrate a database while replicating ongoing changes to reduce cutover downtime. Which AWS DMS task fits?
Use a full load plus CDC task to copy existing data and then apply ongoing changes.
A target already contains the initial database copy. Which AWS DMS task migrates subsequent changes?
A CDC-only task replicates ongoing changes.
A team needs automatic failover for a provisioned AWS DMS replication instance. What should it configure?
Choose Multi-AZ to provision a synchronous standby in a different Availability Zone.
A team does not want to manage replication instance capacity for AWS DMS. What feature should it consider?
DMS Serverless automatically provisions and scales replication capacity.
Does AWS DMS CDC guarantee real-time replication with a latency SLA?
No. CDC latency varies and has no SLA.
A database is moving to a different engine. How can AWS DMS help with the schema and data?
Use DMS Schema Conversion to assess and convert the schema, and DMS to migrate data. Objects that cannot be converted automatically need manual conversion.
A team is migrating to a different database engine with AWS DMS. How can it convert the source schema?
Use DMS Schema Conversion or AWS Schema Conversion Tool. Manually convert objects that automatic conversion cannot handle.
Existing S3 data files and every later change to them must stream into Kinesis Data Streams quickly, with little code. What can bridge them?
AWS DMS, with S3 as the source endpoint and Kinesis Data Streams as the target endpoint, running a full load plus ongoing changes.
A DMS replication from an on-premises MySQL database must encrypt the connection to the source. What do you configure?
An SSL connection on the DMS endpoint, with the database CA certificate imported into DMS and assigned to it.
An application embedded NoSQL data on its servers and now needs a managed NoSQL store. Can AWS DMS move MongoDB data into DynamoDB?
Yes. DMS supports DynamoDB as a target, with a relational database or MongoDB as the source.
Before converting a database schema with DMS Schema Conversion, how can a team see how much manual work the conversion needs?
Run an assessment. It shows what converts automatically and what needs manual work.