SlideShare uma empresa Scribd logo
1 de 7
Page 1 of 7
Re:Modernize
Hands-on Lab
1. Create an Amazon EC2 t2.small instance with Amazon Linux 2
• See documentation at
http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EC2_GetStarted.html
• Create and use a security group that allows inbound TCP
access using SSH (port 22) and MYSQL (port 3306) for all
AWS sources:
172.0.0.0/8
10.0.0.0/8
You might get an automated warning that your EC2 instance is
“open to the world”, because we’re not limiting the source range
for SSH. This is expected. In a production system, you’ll want to
provide a limited IP range for allowed SSH access. For this lab,
disregard the warning.
2. Access the linux console. See documentation at
http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AccessingInstances.htm
l
Use ssh for Linux or Mac; use PuTTY for Windows
Example:
ssh –i ~/Downloads/key.pem ec2-user@ec2-01-02-03-99.us-west-2.compute.amazonaws.com
[ec2-user@ip-192-168-0-1 ~]$
• Install MySql development client
$ sudo yum install mysql
$ sudo yum install mysql-devel
3. Create an Amazon RDS MySQL db.t2.small instance
• See documentation at
http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_GettingStarte
d.CreatingConnecting.MySQL.html
Page 2 of 7
• Name the instance sql-lab. Be sure to choose MySQL (not
Aurora and not MariaDB), the db.t2.small instance size, a
Dev/Test use case, and MySQL version 5.5.57
• Choose a master username and a password (and don’t forget
them!)
• Do not create a database (we will do that later)
• Once the instance is created, find your mysql endpoint name
i. On the AWS Console, choose Services, then RDS
ii. On the RDS dashboard, choose DB Instances
Page 3 of 7
iii. Select your DB Instance
iv. Note your endpoint name. You will need it later!
When using the endpoint name, you usually should not
use the port extension (:3306), just the name.
• Verify you can access the mysql> console from your EC2
instance
$ mysql –h <mysql node name> -u <user name> -p
Example:
$ mysql -h sql-lab.cxpjiluqq0c9.us-west-2.rds.amazonaws.com -u awsuser -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 9999
Server version: 5.6.27-log MySQL Community Server (GPL)
Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
mysql>
To exit from the mysql> prompt, use CTRL-D
Page 4 of 7
4. Download and Prepare Landsat scenes
• See documentation at
https://aws.amazon.com/public-data-sets/landsat/
• From your EC2 instance, download the Landsat scenes
$ wget http://landsat-pds.s3.amazonaws.com/scene_list.gz
• Unzip the scene list
$ gunzip scene_list.gz
5. Load to MySQL
• Log into the mysql> console
• Create a landsat database
mysql> CREATE DATABASE landsat;
mysql> USE landsat;
• Create the scene_list table
mysql> CREATE TABLE scene_list (entityId VARCHAR(64), acquisitionDate
DATETIME,cloudCover DECIMAL(5,2),processingLevel VARCHAR(8),path
INT,row INT,min_lat DECIMAL(8,5),min_lon DECIMAL(8,5),max_lat
DECIMAL(8,5),max_lon DECIMAL(8,5),download_url VARCHAR(128));
• Load the landsat data
mysql> LOAD DATA LOCAL INFILE 'scene_list' INTO TABLE scene_list FIELDS
TERMINATED BY ',';
Page 5 of 7
6. Run SQL query
• Log in to your MySQL node and run a query
mysql> SELECT COUNT(*) FROM scene_list;
7. Create an Amazon RDS MySQL db.r3.large instance
• See documentation at
https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_GettingStarted.
CreatingConnecting.Aurora.html
• Name the instance sql-aurora. Be sure to choose Aurora,
MySQL 5.6-compatible, and the db.r3.largeinstance size. Do
not create a replica in a different Zone.
• Choose a master username and a password (and don’t forget
them!)
• Do not create a database (we will do that later)
• Once the instance is created, find your mysql endpoint name
i. On the AWS Console, choose Services, then RDS
ii. On the RDS dashboard, choose DB Instances
Page 6 of 7
iii. Select your Aurora DB Instance
iv. Note your endpoint name. You will need it later!
When using the endpoint name, you usually should not
use the port extension (:3306), just the name.
• Verify you can access the mysql> console from your EC2
instance
$ mysql –h <mysql node name> -u <user name> -p
Example:
$ mysql -h sql-aurora.cxpuqq0c9.us-west-2.rds.amazonaws.com -u awsuser -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 9999
Server version: 5.6.27-log MySQL Community Server (GPL)
Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
mysql>
To exit from the mysql> prompt, use CTRL-D
8. Create a dms.t2.medium DMS replication instance
• See documentation at
https://us-west-2.console.aws.amazon.com/dms/home?region=us-west-2#create-first-
migration
Name the replication instance dms-lab. Be sure to choose the
dms.t2.medium instance size. Do not choose Multi-AZ.
• Enter source and target database information. Use SSL mode
“none”. Be sure to test each connection
9. Create and start your migration Task
Name the task migrate.
• Enable validation and logging
• Include all tables in the “landsat” schema
• Be sure to START the task once it is created
Page 7 of 7
After the migration is complete, log in to your Aurora instance and run
mysql> SELECT COUNT(*) FROM scene_list;
Did all of the data migrate?

Mais conteúdo relacionado

Mais procurados

How to scheduled jobs in a cloudera cluster without oozie
How to scheduled jobs in a cloudera cluster without oozieHow to scheduled jobs in a cloudera cluster without oozie
How to scheduled jobs in a cloudera cluster without oozieTiago Simões
 
Terraform introduction
Terraform introductionTerraform introduction
Terraform introductionJason Vance
 
How to implement a gdpr solution in a cloudera architecture
How to implement a gdpr solution in a cloudera architectureHow to implement a gdpr solution in a cloudera architecture
How to implement a gdpr solution in a cloudera architectureTiago Simões
 
Amazon AWS Identity Access Management
Amazon AWS Identity Access ManagementAmazon AWS Identity Access Management
Amazon AWS Identity Access ManagementVCP Muthukrishna
 
How to configure amazon ec2 load balancer
How to configure amazon ec2 load balancerHow to configure amazon ec2 load balancer
How to configure amazon ec2 load balancerVCP Muthukrishna
 
Deploy Mediawiki Using FIWARE Lab Facilities
Deploy Mediawiki Using FIWARE Lab FacilitiesDeploy Mediawiki Using FIWARE Lab Facilities
Deploy Mediawiki Using FIWARE Lab FacilitiesFIWARE
 
New features of Azure Cloud Provider in OpenShift Container Platform 3.10
New features of Azure Cloud Provider in OpenShift Container Platform 3.10New features of Azure Cloud Provider in OpenShift Container Platform 3.10
New features of Azure Cloud Provider in OpenShift Container Platform 3.10Takayoshi Tanaka
 
How to Configure Amazon AWS EC2 Elastic IP Address
How to Configure Amazon AWS EC2 Elastic IP AddressHow to Configure Amazon AWS EC2 Elastic IP Address
How to Configure Amazon AWS EC2 Elastic IP AddressVCP Muthukrishna
 
Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부Hyun-Mook Choi
 
Detect and fix the azure sql resources which uses tls version less than 1.2
Detect and fix the azure sql resources which uses tls version less than 1.2Detect and fix the azure sql resources which uses tls version less than 1.2
Detect and fix the azure sql resources which uses tls version less than 1.2Prancer Io
 
How to deploy spark instance using ansible 2.0 in fiware lab v2
How to deploy spark instance using ansible 2.0 in fiware lab v2How to deploy spark instance using ansible 2.0 in fiware lab v2
How to deploy spark instance using ansible 2.0 in fiware lab v2Fernando Lopez Aguilar
 
Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)
Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)
Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)Maarten Balliauw
 
Terraform modules restructured
Terraform modules restructuredTerraform modules restructured
Terraform modules restructuredAmi Mahloof
 
2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server
2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server
2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL ServerScott Sutherland
 
New features of Azure Cloud Provider at OCP 3.10
New features of Azure Cloud Provider at OCP 3.10New features of Azure Cloud Provider at OCP 3.10
New features of Azure Cloud Provider at OCP 3.10Takayoshi Tanaka
 

Mais procurados (20)

AWS essentials S3
AWS essentials S3AWS essentials S3
AWS essentials S3
 
How to scheduled jobs in a cloudera cluster without oozie
How to scheduled jobs in a cloudera cluster without oozieHow to scheduled jobs in a cloudera cluster without oozie
How to scheduled jobs in a cloudera cluster without oozie
 
Terraform introduction
Terraform introductionTerraform introduction
Terraform introduction
 
Terraform day02
Terraform day02Terraform day02
Terraform day02
 
How to implement a gdpr solution in a cloudera architecture
How to implement a gdpr solution in a cloudera architectureHow to implement a gdpr solution in a cloudera architecture
How to implement a gdpr solution in a cloudera architecture
 
Knowledge article
Knowledge articleKnowledge article
Knowledge article
 
Amazon AWS Identity Access Management
Amazon AWS Identity Access ManagementAmazon AWS Identity Access Management
Amazon AWS Identity Access Management
 
How to configure amazon ec2 load balancer
How to configure amazon ec2 load balancerHow to configure amazon ec2 load balancer
How to configure amazon ec2 load balancer
 
Deploy Mediawiki Using FIWARE Lab Facilities
Deploy Mediawiki Using FIWARE Lab FacilitiesDeploy Mediawiki Using FIWARE Lab Facilities
Deploy Mediawiki Using FIWARE Lab Facilities
 
New features of Azure Cloud Provider in OpenShift Container Platform 3.10
New features of Azure Cloud Provider in OpenShift Container Platform 3.10New features of Azure Cloud Provider in OpenShift Container Platform 3.10
New features of Azure Cloud Provider in OpenShift Container Platform 3.10
 
How to Configure Amazon AWS EC2 Elastic IP Address
How to Configure Amazon AWS EC2 Elastic IP AddressHow to Configure Amazon AWS EC2 Elastic IP Address
How to Configure Amazon AWS EC2 Elastic IP Address
 
Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부
 
Detect and fix the azure sql resources which uses tls version less than 1.2
Detect and fix the azure sql resources which uses tls version less than 1.2Detect and fix the azure sql resources which uses tls version less than 1.2
Detect and fix the azure sql resources which uses tls version less than 1.2
 
Terraform day03
Terraform day03Terraform day03
Terraform day03
 
How to deploy spark instance using ansible 2.0 in fiware lab v2
How to deploy spark instance using ansible 2.0 in fiware lab v2How to deploy spark instance using ansible 2.0 in fiware lab v2
How to deploy spark instance using ansible 2.0 in fiware lab v2
 
k8s-on-azure
 k8s-on-azure k8s-on-azure
k8s-on-azure
 
Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)
Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)
Get more than a cache back! The Microsoft Azure Redis Cache (NDC Oslo)
 
Terraform modules restructured
Terraform modules restructuredTerraform modules restructured
Terraform modules restructured
 
2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server
2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server
2018 Student360 - Beyond xp_cmdshell - Owning the Empire Through SQL Server
 
New features of Azure Cloud Provider at OCP 3.10
New features of Azure Cloud Provider at OCP 3.10New features of Azure Cloud Provider at OCP 3.10
New features of Azure Cloud Provider at OCP 3.10
 

Semelhante a Hands-on Lab: re-Modernize - Updating and Consolidating MySQL

Lab Manual Managed Database Basics
Lab Manual Managed Database BasicsLab Manual Managed Database Basics
Lab Manual Managed Database BasicsAmazon Web Services
 
Lab Manual Combaring Redis with Relational
Lab Manual Combaring Redis with RelationalLab Manual Combaring Redis with Relational
Lab Manual Combaring Redis with RelationalAmazon Web Services
 
Hands-on Lab: Amazon ElastiCache
Hands-on Lab: Amazon ElastiCacheHands-on Lab: Amazon ElastiCache
Hands-on Lab: Amazon ElastiCacheAmazon Web Services
 
Getting Started with ElastiCache for Redis
Getting Started with ElastiCache for RedisGetting Started with ElastiCache for Redis
Getting Started with ElastiCache for RedisAmazon Web Services
 
Amazon AWS Workspace Howto
Amazon AWS Workspace HowtoAmazon AWS Workspace Howto
Amazon AWS Workspace Howtomailbhargav
 
Bare Metal to OpenStack with Razor and Chef
Bare Metal to OpenStack with Razor and ChefBare Metal to OpenStack with Razor and Chef
Bare Metal to OpenStack with Razor and ChefMatt Ray
 
[Devconf.cz][2017] Understanding OpenShift Security Context Constraints
[Devconf.cz][2017] Understanding OpenShift Security Context Constraints[Devconf.cz][2017] Understanding OpenShift Security Context Constraints
[Devconf.cz][2017] Understanding OpenShift Security Context ConstraintsAlessandro Arrichiello
 
R server and spark
R server and sparkR server and spark
R server and sparkBAINIDA
 
Reusable, composable, battle-tested Terraform modules
Reusable, composable, battle-tested Terraform modulesReusable, composable, battle-tested Terraform modules
Reusable, composable, battle-tested Terraform modulesYevgeniy Brikman
 
Deploying Windows Containers on Windows Server 2016
Deploying Windows Containers on Windows Server 2016Deploying Windows Containers on Windows Server 2016
Deploying Windows Containers on Windows Server 2016Ben Hall
 
Create and use a Dockerized Aruba Cloud server - CloudConf 2017
Create and use a Dockerized Aruba Cloud server - CloudConf 2017Create and use a Dockerized Aruba Cloud server - CloudConf 2017
Create and use a Dockerized Aruba Cloud server - CloudConf 2017Aruba S.p.A.
 
Automating complex infrastructures with Puppet
Automating complex infrastructures with PuppetAutomating complex infrastructures with Puppet
Automating complex infrastructures with PuppetKris Buytaert
 
Docker Security workshop slides
Docker Security workshop slidesDocker Security workshop slides
Docker Security workshop slidesDocker, Inc.
 
Building an HPC Cluster in 10 Minutes
Building an HPC Cluster in 10 MinutesBuilding an HPC Cluster in 10 Minutes
Building an HPC Cluster in 10 MinutesMonica Rut Avellino
 
Minimal OpenStack LinuxCon NA 2015
Minimal OpenStack LinuxCon NA 2015Minimal OpenStack LinuxCon NA 2015
Minimal OpenStack LinuxCon NA 2015Sean Dague
 
대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016
대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016
대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016Amazon Web Services Korea
 

Semelhante a Hands-on Lab: re-Modernize - Updating and Consolidating MySQL (20)

Lab Manual Managed Database Basics
Lab Manual Managed Database BasicsLab Manual Managed Database Basics
Lab Manual Managed Database Basics
 
Lab Manual Combaring Redis with Relational
Lab Manual Combaring Redis with RelationalLab Manual Combaring Redis with Relational
Lab Manual Combaring Redis with Relational
 
Hands-on Lab: Amazon ElastiCache
Hands-on Lab: Amazon ElastiCacheHands-on Lab: Amazon ElastiCache
Hands-on Lab: Amazon ElastiCache
 
Getting Started with ElastiCache for Redis
Getting Started with ElastiCache for RedisGetting Started with ElastiCache for Redis
Getting Started with ElastiCache for Redis
 
One-Man Ops
One-Man OpsOne-Man Ops
One-Man Ops
 
Amazon AWS Workspace Howto
Amazon AWS Workspace HowtoAmazon AWS Workspace Howto
Amazon AWS Workspace Howto
 
Bare Metal to OpenStack with Razor and Chef
Bare Metal to OpenStack with Razor and ChefBare Metal to OpenStack with Razor and Chef
Bare Metal to OpenStack with Razor and Chef
 
[Devconf.cz][2017] Understanding OpenShift Security Context Constraints
[Devconf.cz][2017] Understanding OpenShift Security Context Constraints[Devconf.cz][2017] Understanding OpenShift Security Context Constraints
[Devconf.cz][2017] Understanding OpenShift Security Context Constraints
 
R server and spark
R server and sparkR server and spark
R server and spark
 
Reusable, composable, battle-tested Terraform modules
Reusable, composable, battle-tested Terraform modulesReusable, composable, battle-tested Terraform modules
Reusable, composable, battle-tested Terraform modules
 
Deploying Windows Containers on Windows Server 2016
Deploying Windows Containers on Windows Server 2016Deploying Windows Containers on Windows Server 2016
Deploying Windows Containers on Windows Server 2016
 
Create and use a Dockerized Aruba Cloud server - CloudConf 2017
Create and use a Dockerized Aruba Cloud server - CloudConf 2017Create and use a Dockerized Aruba Cloud server - CloudConf 2017
Create and use a Dockerized Aruba Cloud server - CloudConf 2017
 
Automating complex infrastructures with Puppet
Automating complex infrastructures with PuppetAutomating complex infrastructures with Puppet
Automating complex infrastructures with Puppet
 
Docker Security workshop slides
Docker Security workshop slidesDocker Security workshop slides
Docker Security workshop slides
 
AWS Serverless Workshop
AWS Serverless WorkshopAWS Serverless Workshop
AWS Serverless Workshop
 
Building an HPC Cluster in 10 Minutes
Building an HPC Cluster in 10 MinutesBuilding an HPC Cluster in 10 Minutes
Building an HPC Cluster in 10 Minutes
 
Minimal OpenStack LinuxCon NA 2015
Minimal OpenStack LinuxCon NA 2015Minimal OpenStack LinuxCon NA 2015
Minimal OpenStack LinuxCon NA 2015
 
Simple docker hosting in FIWARE Lab
Simple docker hosting in FIWARE LabSimple docker hosting in FIWARE Lab
Simple docker hosting in FIWARE Lab
 
Freeradius edir
Freeradius edirFreeradius edir
Freeradius edir
 
대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016
대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016
대용량 데이타 쉽고 빠르게 분석하기 :: 김일호 솔루션즈 아키텍트 :: Gaming on AWS 2016
 

Mais de Amazon Web Services

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Amazon Web Services
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Amazon Web Services
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateAmazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSAmazon Web Services
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Amazon Web Services
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Amazon Web Services
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...Amazon Web Services
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsAmazon Web Services
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareAmazon Web Services
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSAmazon Web Services
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAmazon Web Services
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareAmazon Web Services
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWSAmazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckAmazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without serversAmazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...Amazon Web Services
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceAmazon Web Services
 

Mais de Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

Hands-on Lab: re-Modernize - Updating and Consolidating MySQL

  • 1. Page 1 of 7 Re:Modernize Hands-on Lab 1. Create an Amazon EC2 t2.small instance with Amazon Linux 2 • See documentation at http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EC2_GetStarted.html • Create and use a security group that allows inbound TCP access using SSH (port 22) and MYSQL (port 3306) for all AWS sources: 172.0.0.0/8 10.0.0.0/8 You might get an automated warning that your EC2 instance is “open to the world”, because we’re not limiting the source range for SSH. This is expected. In a production system, you’ll want to provide a limited IP range for allowed SSH access. For this lab, disregard the warning. 2. Access the linux console. See documentation at http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AccessingInstances.htm l Use ssh for Linux or Mac; use PuTTY for Windows Example: ssh –i ~/Downloads/key.pem ec2-user@ec2-01-02-03-99.us-west-2.compute.amazonaws.com [ec2-user@ip-192-168-0-1 ~]$ • Install MySql development client $ sudo yum install mysql $ sudo yum install mysql-devel 3. Create an Amazon RDS MySQL db.t2.small instance • See documentation at http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_GettingStarte d.CreatingConnecting.MySQL.html
  • 2. Page 2 of 7 • Name the instance sql-lab. Be sure to choose MySQL (not Aurora and not MariaDB), the db.t2.small instance size, a Dev/Test use case, and MySQL version 5.5.57 • Choose a master username and a password (and don’t forget them!) • Do not create a database (we will do that later) • Once the instance is created, find your mysql endpoint name i. On the AWS Console, choose Services, then RDS ii. On the RDS dashboard, choose DB Instances
  • 3. Page 3 of 7 iii. Select your DB Instance iv. Note your endpoint name. You will need it later! When using the endpoint name, you usually should not use the port extension (:3306), just the name. • Verify you can access the mysql> console from your EC2 instance $ mysql –h <mysql node name> -u <user name> -p Example: $ mysql -h sql-lab.cxpjiluqq0c9.us-west-2.rds.amazonaws.com -u awsuser -p Enter password: Welcome to the MySQL monitor. Commands end with ; or g. Your MySQL connection id is 9999 Server version: 5.6.27-log MySQL Community Server (GPL) Type 'help;' or 'h' for help. Type 'c' to clear the current input statement. mysql> To exit from the mysql> prompt, use CTRL-D
  • 4. Page 4 of 7 4. Download and Prepare Landsat scenes • See documentation at https://aws.amazon.com/public-data-sets/landsat/ • From your EC2 instance, download the Landsat scenes $ wget http://landsat-pds.s3.amazonaws.com/scene_list.gz • Unzip the scene list $ gunzip scene_list.gz 5. Load to MySQL • Log into the mysql> console • Create a landsat database mysql> CREATE DATABASE landsat; mysql> USE landsat; • Create the scene_list table mysql> CREATE TABLE scene_list (entityId VARCHAR(64), acquisitionDate DATETIME,cloudCover DECIMAL(5,2),processingLevel VARCHAR(8),path INT,row INT,min_lat DECIMAL(8,5),min_lon DECIMAL(8,5),max_lat DECIMAL(8,5),max_lon DECIMAL(8,5),download_url VARCHAR(128)); • Load the landsat data mysql> LOAD DATA LOCAL INFILE 'scene_list' INTO TABLE scene_list FIELDS TERMINATED BY ',';
  • 5. Page 5 of 7 6. Run SQL query • Log in to your MySQL node and run a query mysql> SELECT COUNT(*) FROM scene_list; 7. Create an Amazon RDS MySQL db.r3.large instance • See documentation at https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_GettingStarted. CreatingConnecting.Aurora.html • Name the instance sql-aurora. Be sure to choose Aurora, MySQL 5.6-compatible, and the db.r3.largeinstance size. Do not create a replica in a different Zone. • Choose a master username and a password (and don’t forget them!) • Do not create a database (we will do that later) • Once the instance is created, find your mysql endpoint name i. On the AWS Console, choose Services, then RDS ii. On the RDS dashboard, choose DB Instances
  • 6. Page 6 of 7 iii. Select your Aurora DB Instance iv. Note your endpoint name. You will need it later! When using the endpoint name, you usually should not use the port extension (:3306), just the name. • Verify you can access the mysql> console from your EC2 instance $ mysql –h <mysql node name> -u <user name> -p Example: $ mysql -h sql-aurora.cxpuqq0c9.us-west-2.rds.amazonaws.com -u awsuser -p Enter password: Welcome to the MySQL monitor. Commands end with ; or g. Your MySQL connection id is 9999 Server version: 5.6.27-log MySQL Community Server (GPL) Type 'help;' or 'h' for help. Type 'c' to clear the current input statement. mysql> To exit from the mysql> prompt, use CTRL-D 8. Create a dms.t2.medium DMS replication instance • See documentation at https://us-west-2.console.aws.amazon.com/dms/home?region=us-west-2#create-first- migration Name the replication instance dms-lab. Be sure to choose the dms.t2.medium instance size. Do not choose Multi-AZ. • Enter source and target database information. Use SSL mode “none”. Be sure to test each connection 9. Create and start your migration Task Name the task migrate. • Enable validation and logging • Include all tables in the “landsat” schema • Be sure to START the task once it is created
  • 7. Page 7 of 7 After the migration is complete, log in to your Aurora instance and run mysql> SELECT COUNT(*) FROM scene_list; Did all of the data migrate?