사례로 알아보는 Database Migration Service : 데이터베이스 및 데이터 이관, 통합, 분리, 분석의 도구 - 발표자: 윤기원, Sr Partner Solutions Architect, WWCS, AWS ::: AWS Data Roadshow 2023

Amazon Web Services Korea
Amazon Web Services KoreaAmazon Web Services Korea
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
사례로 알아보는 Database Migration Service
데이터 이관, 통합, 수집의 도구
Kiwon Yoon
Sr. Partner Solutions Architect
AWS Korea
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
2
Who am I ?
❑ 소속
Amazon Web Services Korea
Sr. Partner Solutions Architect
Enterprise 고객 담당
❑ 관심 분야
Database, Migration, Analytics
윤기원 (Kiwon Yoon)
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Agenda
• Schema Conversion Tool (SCT)
• Database Migration Service (DMS)
• Database Migration Service 구성 요소
• Database Migration Service 아키텍처
• Database Migration Service Use Cases
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Database Migration Service에 대한 오해
AWS Database Migration Service (AWS DMS) 는
Database Migration 만을 위한 도구이다?
4
No!!! No!!! No!!!
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Migration 도구
AWS Database Migration Service (AWS DMS) 는
동종/이기종 데이터베이스와 데이터웨어하우스의
데이터를 손쉽게 이관하도록 지원합니다.
Schema Conversion Tool (SCT) 는
동종/이기종 데이터베이스 스키마 및 코드
변환 및 이관 작업을 자동화할 수 있도록 지원합니다.
5
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS SCT
Features
동종/이기종 마이그레이션에 대한 평가 보고서 생성
Database Schema 전환 및 이관
Redshift로의 Schema 전환 및 이관
Application Code 전환/이관
DDL이나 Schema에 대한 Customizing 기능 제공
Bulk Data Load 기능
데이터베이스 스키마 및 코드 변환 작업을 자동화
Source
Database
AWS SCT Target
Database
Convert
6
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS DMS
Features
동종/이기종 데이터베이스간 데이터 이관
현재 데이터 이관 및 Change Data Capture(CDC) 지원
Data Warehouse / Datalake 저장소 데이터 Ingest 지원
Database 통합 및 분리 지원
Disaster Recovery & Read Replica 구성
데이터베이스 엔진 별 일부 DDL 지원
데이터를 다양한 데이터 원본 및 대상으로 이관
Source
Repository
AWS DMS Target
Repository
Migrate
7
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
DMS에 의해 지원되는 원본 및 대상
NOSQL
RELATIONAL ANALYTICS DATA WAREHOUSE
Amazon S3
AWS Snowball
MongoDB
Cassandra
Amazon DocumentDB
Netezza
Azure
Synapse
Greenplum Teradata
Vertica
Oracle
MySQL Amazon Aurora
PostgreSQL
SQL Server
SQL Azure
MariaDB
SAP ASE IBM Db2 LUW
GCP MySQL
SOURCES
TARGETS
Amazon DynamoDB
Amazon DocumentDB
Amazon Neptune
Amazon OpenSearch
Service
Amazon Kinesis Data
Streams
Amazon S3
Amazon Managed
Streaming for Kafka
Amazon Redshift
Oracle
MySQL Amazon Aurora
PostgreSQL
SQL Server
MariaDB
SAP ASE
Amazon
ElastiCache
Oracle
SQL
Server
IBM Db2 z/OS
Oracle, Java, and MySQL are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.
Amazon RDS
Amazon RDS
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
S
O
U
R
C
E
T
A
R
G
E
T
DB on EC2
instance
Amazon RDS
DB instance
On-premises
database
S3
Amazon RDS
DB instance
On-premises
database
Replication
instance
DMS Tasks
Database Migration Service(DMS) 구성 요소
9
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Database Migration Service 구성 요소
Replication Instance
Endpoint
Task
데이터베이스 간의 데이터 이동과 복제 작업을 위한
EC2 인스턴스
이관 데이터양에 기반한 Instance Sizing 가능
DMS Serverless 기능 출시(DMS capacity Unit 지정)
고가용성 보장 및 복제 지연 모니터링 지원
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Database Migration Service 구성 요소
Replication Instance
Endpoint
Task
원본/ 대상 데이터베이스 접속 Endpoint
• Source Endpoint
• Target Endpoint
Extra Connection을 통한 다양한 Endpoint 설정 가능
- 통신간 암호화 설정
- Data Encoding 및 Timezone 변경
- 성능 최적화 Parameter 설정
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Database Migration Service 구성 요소
Replication Instance
Endpoint
Task
원본과 대상 엔드포인트 간의 데이터 이동과 변환 설정 및 관리
• Replication Instance 선택 및 Endpoint 연결
• Migration Type 선택 – Full Load/ Full Load & CDC/ CDC only
• Target Preparation – Do Nothing/ Drop Tables/ Truncate
• Enable Validation
• Enable Logging
• 이관 대상 Schema-Object 선택
• 조건절을 이용한 특정 데이터 이관
• 변환 규칙을 이용한 변환 작업
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
DMS Use Cases
데이터 이관 및 복제
Full Load
CDC
DEV / UAT / TEST
데이터베이스 생성
데이터베이스
통합 및 분리
재해 복구 DR 용도
읽기 전용 DB 용도
DW – Redshift
Datalake – S3
3rd Party Solutions
13
조건 데이터 이관
PII 칼럼 제외
스키마 변환
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Use Case : 데이터베이스 이관 및 복제
동종/이기종 데이터베이스의 데이터 이관 및 복제
Full Load
• DMS Task 수행 시점의 초기 데이터를 1회성으로 전체 이관 수행
• Downtime이 충분한 경우 or 작은 Table들을 Cut-Over 시점에 이관 시 사용
Full Load + CDC
• 초기 데이터를 이관 후 변경 데이터를 자동 반영
• 짧은 Downtime 안에서 대량 Table 이관 시 사용
CDC Only
• 초기 데이터는 다른 방법으로 이관 후 변경 데이터만 DMS로 반영
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
변경 데이터 캡처(CDC)
복제 인스턴스
대상
트랜잭션
초기 데이터 로드 후
변경 데이터 반영
t1
t2
소스
t1 t2
업데이트
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Use Case : 개발/테스트용 DB 생성
개발/테스트용 DB 생성을 위해 Cloning(디비 클로닝) 필요
- Database on EC2의 경우 AMI, Snapshot을 이용하여 Cloning 수행
- Managed RDS의 경우 Snapshot 활용
• 두 방식 모두 원본 DB와 동일한 스토리지 필요
- 필요 Schema 혹은 Table만 개발/테스트용 DB로 이관
1) Cloning 시간 감소
2) Storage 공간 절약
3) 보안성 강화
4) 개발 인스턴스 활용도 증가
5) 데이터의 실시간성 증가
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Use Case : 데이터베이스 통합 및 분리
데이터베이스 통합 (Database Consolidation)
- 인스턴스 비용 감소
- 데이터 일관성 증가
- 인터페이스 비용 감소
데이터베이스 분리 (Database Split or Data Archiving)
- Micro Service Architecture를 위한 DB 분리 가능
- DB Link 류의 Interfacing 대체 가능
- 보안 정책 요건 충족
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
데이터 병합
대상
복제
인스턴스
ORDER
INVENTORY
ClickStream
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
데이터 분리
HR
복제
인스턴스
원본
FIN
SALES
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Use Case : HA / DR / Read Replica / Seamless Upgrade
가용성(High Availability) 확보
- Primary / Standby 구성
재해복구(Disaster Recovery) DB 구성
- Hybrid DR or Cross Region DR
Active – Active DB Replication 구성
- 양방향 동기화를 통한 Multi Write Instance
읽기 워크로드 처리용 Read Replica 구성
Seamless Upgrade
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Use Case : 특정 조건 데이터 이관/마스킹 및 스키마 변환
특정 조건에 기반한 Data 이관 기능 (Query의 Where Filtering과 유사)
- 필요 Data만 추출하여 이관
- 정책에 기반한 데이터 아카이빙
- 특정 파티션 데이터에 대한 분리 및 이관
민감 데이터 칼럼 제외 기능
- 사용자 식별 데이터등 불필요 칼럼 제외 이관
- 스키마 구조를 유지하면서, 특정 Column Data Masking 기능
스키마, 테이블, 칼럼 이름 변경 등 간단한 ETL 가능
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
데이터 필터링
복제 인스턴스
소스 대상
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Use Case : Redshift, S3 Datalake, 3rd Party Solutions
Data Warehouse – Redshift 데이터 적재 기능
- Redshift Cluster로 직접 적재
- Redshift Spectrum S3 저장소로 적재
- JSON Data 적재 기능
Datalake – S3로 초기 데이터 및 변경 데이터 적재 기능
3rd Party Solutions(Snowflake, Databricks) 용 데이터 적재 기능
- S3 저장소로 초기 데이터 및 변경 데이터 적재 기능
- DMS – MSK를 활용한 CDC 데이터 적재 기능
RDBMS Data Warehouse 적재 용도
AWS DATA ROADSHOW 2023
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Thank you!
Kiwon Yoon
kiwony@amazon.com
24
1 sur 24

Contenu connexe

Tendances(20)

Similaire à 사례로 알아보는 Database Migration Service : 데이터베이스 및 데이터 이관, 통합, 분리, 분석의 도구 - 발표자: 윤기원, Sr Partner Solutions Architect, WWCS, AWS ::: AWS Data Roadshow 2023(20)

AWS Modern Infra with Storage Roadshow 2023 - Day 2AWS Modern Infra with Storage Roadshow 2023 - Day 2
AWS Modern Infra with Storage Roadshow 2023 - Day 2
Amazon Web Services Korea169 vues

Plus de Amazon Web Services Korea(12)

AWS Modern Infra with Storage Roadshow 2023 - Day 1AWS Modern Infra with Storage Roadshow 2023 - Day 1
AWS Modern Infra with Storage Roadshow 2023 - Day 1
Amazon Web Services Korea102 vues

사례로 알아보는 Database Migration Service : 데이터베이스 및 데이터 이관, 통합, 분리, 분석의 도구 - 발표자: 윤기원, Sr Partner Solutions Architect, WWCS, AWS ::: AWS Data Roadshow 2023

  • 1. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. 사례로 알아보는 Database Migration Service 데이터 이관, 통합, 수집의 도구 Kiwon Yoon Sr. Partner Solutions Architect AWS Korea
  • 2. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. 2 Who am I ? ❑ 소속 Amazon Web Services Korea Sr. Partner Solutions Architect Enterprise 고객 담당 ❑ 관심 분야 Database, Migration, Analytics 윤기원 (Kiwon Yoon)
  • 3. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Agenda • Schema Conversion Tool (SCT) • Database Migration Service (DMS) • Database Migration Service 구성 요소 • Database Migration Service 아키텍처 • Database Migration Service Use Cases
  • 4. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Database Migration Service에 대한 오해 AWS Database Migration Service (AWS DMS) 는 Database Migration 만을 위한 도구이다? 4 No!!! No!!! No!!!
  • 5. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. AWS Migration 도구 AWS Database Migration Service (AWS DMS) 는 동종/이기종 데이터베이스와 데이터웨어하우스의 데이터를 손쉽게 이관하도록 지원합니다. Schema Conversion Tool (SCT) 는 동종/이기종 데이터베이스 스키마 및 코드 변환 및 이관 작업을 자동화할 수 있도록 지원합니다. 5
  • 6. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. AWS SCT Features 동종/이기종 마이그레이션에 대한 평가 보고서 생성 Database Schema 전환 및 이관 Redshift로의 Schema 전환 및 이관 Application Code 전환/이관 DDL이나 Schema에 대한 Customizing 기능 제공 Bulk Data Load 기능 데이터베이스 스키마 및 코드 변환 작업을 자동화 Source Database AWS SCT Target Database Convert 6
  • 7. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. AWS DMS Features 동종/이기종 데이터베이스간 데이터 이관 현재 데이터 이관 및 Change Data Capture(CDC) 지원 Data Warehouse / Datalake 저장소 데이터 Ingest 지원 Database 통합 및 분리 지원 Disaster Recovery & Read Replica 구성 데이터베이스 엔진 별 일부 DDL 지원 데이터를 다양한 데이터 원본 및 대상으로 이관 Source Repository AWS DMS Target Repository Migrate 7
  • 8. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. DMS에 의해 지원되는 원본 및 대상 NOSQL RELATIONAL ANALYTICS DATA WAREHOUSE Amazon S3 AWS Snowball MongoDB Cassandra Amazon DocumentDB Netezza Azure Synapse Greenplum Teradata Vertica Oracle MySQL Amazon Aurora PostgreSQL SQL Server SQL Azure MariaDB SAP ASE IBM Db2 LUW GCP MySQL SOURCES TARGETS Amazon DynamoDB Amazon DocumentDB Amazon Neptune Amazon OpenSearch Service Amazon Kinesis Data Streams Amazon S3 Amazon Managed Streaming for Kafka Amazon Redshift Oracle MySQL Amazon Aurora PostgreSQL SQL Server MariaDB SAP ASE Amazon ElastiCache Oracle SQL Server IBM Db2 z/OS Oracle, Java, and MySQL are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. Amazon RDS Amazon RDS
  • 9. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. S O U R C E T A R G E T DB on EC2 instance Amazon RDS DB instance On-premises database S3 Amazon RDS DB instance On-premises database Replication instance DMS Tasks Database Migration Service(DMS) 구성 요소 9
  • 10. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Database Migration Service 구성 요소 Replication Instance Endpoint Task 데이터베이스 간의 데이터 이동과 복제 작업을 위한 EC2 인스턴스 이관 데이터양에 기반한 Instance Sizing 가능 DMS Serverless 기능 출시(DMS capacity Unit 지정) 고가용성 보장 및 복제 지연 모니터링 지원
  • 11. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Database Migration Service 구성 요소 Replication Instance Endpoint Task 원본/ 대상 데이터베이스 접속 Endpoint • Source Endpoint • Target Endpoint Extra Connection을 통한 다양한 Endpoint 설정 가능 - 통신간 암호화 설정 - Data Encoding 및 Timezone 변경 - 성능 최적화 Parameter 설정
  • 12. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Database Migration Service 구성 요소 Replication Instance Endpoint Task 원본과 대상 엔드포인트 간의 데이터 이동과 변환 설정 및 관리 • Replication Instance 선택 및 Endpoint 연결 • Migration Type 선택 – Full Load/ Full Load & CDC/ CDC only • Target Preparation – Do Nothing/ Drop Tables/ Truncate • Enable Validation • Enable Logging • 이관 대상 Schema-Object 선택 • 조건절을 이용한 특정 데이터 이관 • 변환 규칙을 이용한 변환 작업
  • 13. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. DMS Use Cases 데이터 이관 및 복제 Full Load CDC DEV / UAT / TEST 데이터베이스 생성 데이터베이스 통합 및 분리 재해 복구 DR 용도 읽기 전용 DB 용도 DW – Redshift Datalake – S3 3rd Party Solutions 13 조건 데이터 이관 PII 칼럼 제외 스키마 변환
  • 14. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Use Case : 데이터베이스 이관 및 복제 동종/이기종 데이터베이스의 데이터 이관 및 복제 Full Load • DMS Task 수행 시점의 초기 데이터를 1회성으로 전체 이관 수행 • Downtime이 충분한 경우 or 작은 Table들을 Cut-Over 시점에 이관 시 사용 Full Load + CDC • 초기 데이터를 이관 후 변경 데이터를 자동 반영 • 짧은 Downtime 안에서 대량 Table 이관 시 사용 CDC Only • 초기 데이터는 다른 방법으로 이관 후 변경 데이터만 DMS로 반영
  • 15. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. 변경 데이터 캡처(CDC) 복제 인스턴스 대상 트랜잭션 초기 데이터 로드 후 변경 데이터 반영 t1 t2 소스 t1 t2 업데이트
  • 16. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Use Case : 개발/테스트용 DB 생성 개발/테스트용 DB 생성을 위해 Cloning(디비 클로닝) 필요 - Database on EC2의 경우 AMI, Snapshot을 이용하여 Cloning 수행 - Managed RDS의 경우 Snapshot 활용 • 두 방식 모두 원본 DB와 동일한 스토리지 필요 - 필요 Schema 혹은 Table만 개발/테스트용 DB로 이관 1) Cloning 시간 감소 2) Storage 공간 절약 3) 보안성 강화 4) 개발 인스턴스 활용도 증가 5) 데이터의 실시간성 증가
  • 17. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Use Case : 데이터베이스 통합 및 분리 데이터베이스 통합 (Database Consolidation) - 인스턴스 비용 감소 - 데이터 일관성 증가 - 인터페이스 비용 감소 데이터베이스 분리 (Database Split or Data Archiving) - Micro Service Architecture를 위한 DB 분리 가능 - DB Link 류의 Interfacing 대체 가능 - 보안 정책 요건 충족
  • 18. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. 데이터 병합 대상 복제 인스턴스 ORDER INVENTORY ClickStream
  • 19. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. 데이터 분리 HR 복제 인스턴스 원본 FIN SALES
  • 20. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Use Case : HA / DR / Read Replica / Seamless Upgrade 가용성(High Availability) 확보 - Primary / Standby 구성 재해복구(Disaster Recovery) DB 구성 - Hybrid DR or Cross Region DR Active – Active DB Replication 구성 - 양방향 동기화를 통한 Multi Write Instance 읽기 워크로드 처리용 Read Replica 구성 Seamless Upgrade
  • 21. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Use Case : 특정 조건 데이터 이관/마스킹 및 스키마 변환 특정 조건에 기반한 Data 이관 기능 (Query의 Where Filtering과 유사) - 필요 Data만 추출하여 이관 - 정책에 기반한 데이터 아카이빙 - 특정 파티션 데이터에 대한 분리 및 이관 민감 데이터 칼럼 제외 기능 - 사용자 식별 데이터등 불필요 칼럼 제외 이관 - 스키마 구조를 유지하면서, 특정 Column Data Masking 기능 스키마, 테이블, 칼럼 이름 변경 등 간단한 ETL 가능
  • 22. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. 데이터 필터링 복제 인스턴스 소스 대상
  • 23. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Use Case : Redshift, S3 Datalake, 3rd Party Solutions Data Warehouse – Redshift 데이터 적재 기능 - Redshift Cluster로 직접 적재 - Redshift Spectrum S3 저장소로 적재 - JSON Data 적재 기능 Datalake – S3로 초기 데이터 및 변경 데이터 적재 기능 3rd Party Solutions(Snowflake, Databricks) 용 데이터 적재 기능 - S3 저장소로 초기 데이터 및 변경 데이터 적재 기능 - DMS – MSK를 활용한 CDC 데이터 적재 기능 RDBMS Data Warehouse 적재 용도
  • 24. AWS DATA ROADSHOW 2023 © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. © 2023, Amazon Web Services, Inc. or its affiliates. All rights reserved. Thank you! Kiwon Yoon kiwony@amazon.com 24