32
© 2016, Amazon Web Services, Inc. or its Affiliates. All rights reserved. DAT323 Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS John Winford, Raul Frias, Ed Murray November 29 and December 1, 2016

AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Embed Size (px)

Citation preview

Page 1: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

© 2016, Amazon Web Services, Inc. or its Affiliates. All rights reserved.

DAT323

Converting Your Oracle or Microsoft SQL Server

Database to an Open Source Amazon Aurora or

PostgreSQL Database Using AWS SCT and AWS DMS

John Winford, Raul Frias, Ed Murray

November 29 and December 1, 2016

Page 2: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

How can I get to the cloud?

How will my on-premises data migrate to the cloud?

How can I make it transparent to my users?

Afterwards, how will on-premises and cloud data interact?

How can I integrate my data assets within AWS?

Page 3: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Migration used to be cost + complexity + time

Commercial data migration and replication software

Complex to set up and manage

Application downtime

Database-engine-specific application code

Page 4: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Start your first migration in 10 minutes or less

Keep your apps running during the migration

Replicate within, to, or from Amazon EC2 or Amazon RDS

Move data to the same or a different database engine

AWS

Database Migration

Service

(AWS DMS)

Amazon Aurora

Page 5: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Customer

premises

Application users

AWS

Internet

VPN

Start a replication instance

Connect to source and target databases

Select tables, schemas, or databases

Let AWS DMS create tables, load data, and keep them in sync

Switch applications over to the target at your convenience

Keep your apps running during the migration

AWS

DMS

Page 6: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Load is table by table

Replication instance

Source Target

Page 7: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Change data capture (CDC) and apply

Replication instance

Source Target

Update

t1 t2

t1

t2

Transactions Change

apply

after bulk

load

Page 8: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Multi-AZ option for high availability

Customer

premises

or AWS

AWS

Internet

VPN

AWS DMS

AWS DMS

Page 9: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Replication

instance

Source Target

What else can I do?

Source

Source

Page 10: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Replication

instance

Source Target

What else can I do?

Target

Target

Page 11: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

AWS Schema Conversion Tool

Features

Oracle and Microsoft SQL Server schema conversion to MySQL, Amazon Aurora, MariaDB, and PostgreSQL

Or convert your schema between PostgreSQL and any MySQL engine

Database Migration Assessment report for choosing the best target engine

Code browser that highlights places where manual edits are required

Secure connections to your databases with SSL

Cloud native code optimization

The AWS Schema Conversion Tool helps automate

many database schema and code conversion tasks

when migrating between database engines or data

warehouse engines

Page 12: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

SCT helps convert tables, views, and code

Sequences

User-defined types

Synonyms

Packages

Stored procedures

Functions

Triggers

Schemas

Tables

Indexes

Views

Sort and distribution keys

Page 13: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Take it all—or not

Source Target

Replication instance

instance

Page 14: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Homogenous or heterogeneous

Replication

instance

SQL Server MySQL

Replication

instance

Oracle Oracle

Replication

instance

Oracle Aurora

Page 15: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Other database migration use cases

Migration of business-critical applications

Migration from Classic to VPC

Cheap Read Replicas for Oracle

Read Replicas for other engines

Cross-region Read Replicas for Oracle and SQL Server

Analytics in the cloud

Dev/test and production environment sync

Ongoing replication for BI

Minor version upgrade

Page 16: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Database migration process

Page 17: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Resources available to customers—AWS SCT

User Guide: Review technical

docs ataws.amazon.com/documentation/SchemaConversionTool/

or choose the Download button.

Download area: Get installation

files for AWS SCT.

Support forums: Ask questions

and review how-to guides.https://forums.aws.amazon.com/forum.jspa?forumID=208.

Page 18: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Okay—so what’s next?

Page 19: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Database migration challenge

Page 20: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

This is a competition!

Page 21: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

There will be prizes!

Probably not money

Page 22: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Use SCT and DMS migrate a database

Your job(Should you choose to accept it)

SQL

Server

Oracle Aurora

Postgre

SQL

SCT

DMS

From To

Or Or

Page 23: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

We will provide

• Source database

(Mock ticketing system in Oracle or SQL Server—your choice)

• Target database(PostgreSQL or Aurora—your choice)

• Technical support(Ask all the questions you want! We’re here to help.)

Postgre

SQLAurora

SQL

ServerOracle

Page 24: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

To win you will need to

Organize into teams (6–8 per team)

Download and install SCT

Convert your database using SCT

Migrate your source data to your target DB

Generate transactions on your source DB

Page 25: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

You’ll also need to be first!

Page 26: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Don’t worry, you have three chances to be first!

1. Best team name as voted by your peers

2. First team to migrate 1 source database to 1 target database

3. First team to migrate both source databases to the target

databases (1 source to 1 target)

Page 27: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

What does it mean to “migrate” a

database?

1. You must use SCT to create the target schema

2. You must use DMS to migrate the data from the source

database(s) to the target database(s)

3. You must use the procedure generateTicketActivity to generate

transactions on the source DB, and they must be replicated to the

target

Page 28: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Secrets to success…

• Get to know your team members

• Find out who knows what

• Decide on a strategy

For example: Can you break the challenge up into parts?

• Use your help! (That’s us.)

Page 29: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Follow the Amazon S3 link…

(provided during the workshop)

… to download connection details

Page 30: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Good luck!

Page 31: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Thank you!

Page 32: AWS re:Invent 2016: Workshop: Converting Your Oracle or Microsoft SQL Server Database to an Open Source Amazon Aurora or PostgreSQL Database Using AWS SCT and AWS DMS (DAT323)

Remember to complete

your evaluations!