SlideShare una empresa de Scribd logo
1 de 10
Migrating AWS instances between regions<br />This paper describes the process for migrating AWS running instances between regions.  There are various combinations that apply to this process such as:<br />Migrating EBS AMI’s between regions<br />Migrating EBS Snapshots between regions<br />Migrating EBS Volumes on running instances between regions<br />Migrating running AWS instances between regions<br />The process<br />In each of the above scenarios, the main starting point is to have an EBS volume to work with. Once this is achieved the process is mostly the same. This paper will focus on scenario 1 in the above list. Scenarios 2 – 4 are pretty straight forward once you understand the basic process for scenario 1.<br />For this paper we will be migrating an AMI in US-EAST to an AMI in US-WEST<br />Step 1 – Starting with an AMI in US-EAST<br />The AMI we will be starting with is a Fedora AMI based on Fedora 64bit, in the image below you can see it labeled 193564345407/migrate_me_src:<br />EBS AMI<br />Identify the AMI-id of the AMI and then select the list of EBS snapshots. The snapshot that is used as the basis for the AMI will be labeled in the Description colum as Created by CreateImage (IMAGE-id) for AMI-id from vol-id. The AMI-id is what you will be looking for to match to the AMI-id of the AMI you are migrating:<br />Finding the AMI-id<br />Step 2 – Create a Volume from the AMI Root snapshot<br />Once you have identified the root volume snapshot for the AMI, the next thing you will need to do is create a Volume from the snapshot. The easiest way to do this is to right click directly on the snapshot and select create volume.<br />Creating a volume from a snapshot<br />Once you have created the new Volume it is a good idea to set the Name Tag so that you can recognize it easily.<br />Step 3 – Mount the volume on a running EC2 instance<br />Now that you have a Volume ready to go, the next step is to mount it onto a running EC2 instance. The easiest way to do this is to start up a Micro instance specifically for the job, then destroy it afterwards. <br />So go ahead and start up a Micro instance, and attach the Volume from the previous step to /dev/sdf on the new instance.<br />Remember to start up the Micro instance in the same availability zone as the Volume created in the previous step or you won’t be able to attach it!<br />Step 4 – Configure a receiving instance in the destination region<br />Now that we have the source region configured and ready to go we need to set up the destination region. To do this we will need to set up another Micro EC2 instance with a blank Volume attached to /dev/sdf of the same size as the source volume.<br />So go ahead and create a new blank Volume in the destination region and attach it to a new Micro EC2 instance. <br />When you create the new Micro instance in the destination region, create a new Key Pair just for this instance, as we will be copying the private key to the source server in the next step.<br />New EC2 instance in the destination region<br />Step 5 – Copy the private key to the source server<br />Now that we have the desination server running, the next step is to copy the private key used to start the server across to the /tmp directory on the source server. The easiest way to do this is as follows:<br />Right click the source EC2 instance and select Connect to Server option and copy this command.<br />Select Connect on the source server<br />Copy the ssh command:<br />Copying the ssh command<br />On your own laptop or computer, change directory to the directory where you saved your new private key and paste the same command but make the following changes.<br />ssh -i ping-us-east.pem root@ec2-50-19-5-173.compute-1.amazonaws.com<br />to<br />scp -i ping-us-east.pem ping-us-west.pem root@ec2-50-19-5-173.compute-1.amazonaws.com:/tmp<br />This command will use the private key of the source server (ping-us-east.pem) to allow scp (a secure copy program) to connect and copy the private key (ping-us-west.pem) of the destination server to the source server’s /tmp directory.<br />This example assumes that you have a mac or unix laptop or PC, to execute the scp command under windows you will need to download a windows scp tool.<br />Copying up the private key to the source server<br />Step 6 – Copy the volume contents from the source server to the destination server.<br />This step is the most time consuming step of the process and involves actually copying the data between the two volumes in the separate regions.<br />The visual process for copying the data is as follows:<br />Process for copying data between regions<br />Log onto the source server and run the following commands (making sure you change the key pair name and the name of the destination server)<br />$> cd /tmp <br />$> dd if=/dev/sdf |gzip -c -1 | ssh -i ping-us-west.pem root@ec2-50-18-32-121.us-west-1.compute.amazonaws.com quot;
gunzip -c -1 | dd of=/dev/sdfquot;
<br />To break this command down the steps are:<br />dd reads /dev/sdf on the source machine (dd if=/dev/sdf) and sends the result to std out.<br />gzip reads from std in and sends the compressed output to std out<br />ssh reads from std in and pipes the data over the wire to the following command on the destination machine: quot;
gunzip -c -1 | dd of=/dev/sdfquot;
<br />gunzip on the destination machine reads from std in (ssh) and sends the uncompress output to std out.<br />dd reads from std in and writes the output to /dev/sdf<br />The copy process takes about an hour between US-EAST and US-WEST, although I would expect it to take much longer between the other regions.<br />One of the great reasons for doing it this way is that you don’t mount the volume on either the source or the destination server from the operating system, and there is no file system creation required on the destination volume.<br />Step 7 – Create an AMI in the destination region<br />To create an AMI in the destination region you will need to do two steps:<br />Create a snapshot of the volume we just populated with data<br />Create an AMI from the snapshot<br />To create a snapshot, once again it is just a matter of identifying the correct volume in the EBS volumes manage and right click Create Snapshot.<br />Creating a snapshot from a volume<br />Once the snapshot has been created, identify it in the EBS Snapshots. <br />Right click on the snapshot and select Create Image from Snapshot.<br />Creating an image from a snapshot<br />Once you have selected this option the following dialog will be presented:<br />Create snapshot dialog<br />Make sure you select the same architecture type as the original AMI, (in this case the original AMI was fedora 64 bit), and give it a name. you should be able to use the default options for the rest.<br />It may be that you were using an older AMI in the source region or that the Kernel ID or Ramdisk ID’s don’t work. In this case I would recommend starting up an existing AMI in the destination region that is as close as you can get to your existing AMI and copying the Ramdisk ID and Kernel ID’s from the running instance<br />That’s it!<br />Your new AMI should now be available:<br />New AMI<br />Summary<br />In this paper we looked at the process for copying an EBS backed AMI between regions. The process used was a generic process and can be used for not only copying AMI’s between regions, but for copying generic EBS backed volumes.<br />
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions
GUIDE - Migrating AWS EBS backed AMI's between Regions

Más contenido relacionado

La actualidad más candente

Journey to Microservice architecture via Amazon Lambda
Journey to Microservice architecture via Amazon LambdaJourney to Microservice architecture via Amazon Lambda
Journey to Microservice architecture via Amazon LambdaAxilis
 
Using RStudio on AWS
Using RStudio on AWSUsing RStudio on AWS
Using RStudio on AWSBarry DeCicco
 
Testing Ansible with Jenkins and Docker
Testing Ansible with Jenkins and DockerTesting Ansible with Jenkins and Docker
Testing Ansible with Jenkins and DockerDennis Rowe
 
A Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy SystemA Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy Systemadrian_nye
 
A preview of Feathers 2.2 and the Feathers SDK
A preview of Feathers 2.2 and the Feathers SDKA preview of Feathers 2.2 and the Feathers SDK
A preview of Feathers 2.2 and the Feathers SDKJosh Tynjala
 
Fabric-让部署变得简单
Fabric-让部署变得简单Fabric-让部署变得简单
Fabric-让部署变得简单Eric Lo
 
Xen Installation Presentation
Xen Installation Presentation Xen Installation Presentation
Xen Installation Presentation Abhijeet Patil
 
Automated Deployment with Fabric
Automated Deployment with FabricAutomated Deployment with Fabric
Automated Deployment with Fabrictanihito
 
Installing Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu InstanceInstalling Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu Instancekamarul kawnayeen
 
EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...
EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...
EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...AWSKRUG - AWS한국사용자모임
 
전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020
전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020 전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020
전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020 AWSKRUG - AWS한국사용자모임
 
Continuous Deployment at Spreaker
Continuous Deployment at SpreakerContinuous Deployment at Spreaker
Continuous Deployment at SpreakerMarco Pracucci
 
Running a Lean Startup with AWS - Spreaker Case Study
Running a Lean Startup with AWS - Spreaker Case StudyRunning a Lean Startup with AWS - Spreaker Case Study
Running a Lean Startup with AWS - Spreaker Case StudyMarco Pracucci
 
Justin Corbin Portfolio Labs
Justin Corbin Portfolio LabsJustin Corbin Portfolio Labs
Justin Corbin Portfolio LabsJustin Corbin
 
How to deploy docker container inside ikoula's cloud
How to deploy docker container inside ikoula's cloudHow to deploy docker container inside ikoula's cloud
How to deploy docker container inside ikoula's cloudNicolas Trauwaen
 
Adobe AIR for mobile games
Adobe AIR for mobile gamesAdobe AIR for mobile games
Adobe AIR for mobile gamesJames Wrightson
 
Unreal Engine Basics 02 - Unreal Editor
Unreal Engine Basics 02 - Unreal EditorUnreal Engine Basics 02 - Unreal Editor
Unreal Engine Basics 02 - Unreal EditorNick Pruehs
 

La actualidad más candente (20)

Journey to Microservice architecture via Amazon Lambda
Journey to Microservice architecture via Amazon LambdaJourney to Microservice architecture via Amazon Lambda
Journey to Microservice architecture via Amazon Lambda
 
Hadoop presentation
Hadoop presentationHadoop presentation
Hadoop presentation
 
Using RStudio on AWS
Using RStudio on AWSUsing RStudio on AWS
Using RStudio on AWS
 
Testing Ansible with Jenkins and Docker
Testing Ansible with Jenkins and DockerTesting Ansible with Jenkins and Docker
Testing Ansible with Jenkins and Docker
 
A Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy SystemA Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy System
 
A preview of Feathers 2.2 and the Feathers SDK
A preview of Feathers 2.2 and the Feathers SDKA preview of Feathers 2.2 and the Feathers SDK
A preview of Feathers 2.2 and the Feathers SDK
 
Fabric-让部署变得简单
Fabric-让部署变得简单Fabric-让部署变得简单
Fabric-让部署变得简单
 
Fabric: A Capistrano Alternative
Fabric:  A Capistrano AlternativeFabric:  A Capistrano Alternative
Fabric: A Capistrano Alternative
 
Xen Installation Presentation
Xen Installation Presentation Xen Installation Presentation
Xen Installation Presentation
 
Knowledge article
Knowledge articleKnowledge article
Knowledge article
 
Automated Deployment with Fabric
Automated Deployment with FabricAutomated Deployment with Fabric
Automated Deployment with Fabric
 
Installing Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu InstanceInstalling Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu Instance
 
EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...
EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...
EKS에서 Opentelemetry로 코드실행 모니터링하기 - 신재현 (인덴트코퍼레이션) :: AWS Community Day Online...
 
전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020
전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020 전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020
전 세계 팬들이 모일 수 있는 플랫폼 만들기 - 강진우 (beNX) :: AWS Community Day 2020
 
Continuous Deployment at Spreaker
Continuous Deployment at SpreakerContinuous Deployment at Spreaker
Continuous Deployment at Spreaker
 
Running a Lean Startup with AWS - Spreaker Case Study
Running a Lean Startup with AWS - Spreaker Case StudyRunning a Lean Startup with AWS - Spreaker Case Study
Running a Lean Startup with AWS - Spreaker Case Study
 
Justin Corbin Portfolio Labs
Justin Corbin Portfolio LabsJustin Corbin Portfolio Labs
Justin Corbin Portfolio Labs
 
How to deploy docker container inside ikoula's cloud
How to deploy docker container inside ikoula's cloudHow to deploy docker container inside ikoula's cloud
How to deploy docker container inside ikoula's cloud
 
Adobe AIR for mobile games
Adobe AIR for mobile gamesAdobe AIR for mobile games
Adobe AIR for mobile games
 
Unreal Engine Basics 02 - Unreal Editor
Unreal Engine Basics 02 - Unreal EditorUnreal Engine Basics 02 - Unreal Editor
Unreal Engine Basics 02 - Unreal Editor
 

Destacado

Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013
Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013
Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013Amazon Web Services
 
(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014
(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014
(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014Amazon Web Services
 
(DEV301) Automating AWS with the AWS CLI
(DEV301) Automating AWS with the AWS CLI(DEV301) Automating AWS with the AWS CLI
(DEV301) Automating AWS with the AWS CLIAmazon Web Services
 
Retailin france 2011_kh
Retailin france 2011_khRetailin france 2011_kh
Retailin france 2011_khAllystephen
 
Ghosts of gone birds the brief
Ghosts of gone birds the briefGhosts of gone birds the brief
Ghosts of gone birds the briefghostsofgonebirds
 
Restaurant 7 Portes in "La Vanguardia" neswpaper
Restaurant 7 Portes in "La Vanguardia" neswpaperRestaurant 7 Portes in "La Vanguardia" neswpaper
Restaurant 7 Portes in "La Vanguardia" neswpaper7Portes
 
Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)
Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)
Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)SocialMediaClubCA
 
Technology & Education
Technology & EducationTechnology & Education
Technology & Educationkeierlebta
 
Sonipat utility p pt.
Sonipat utility p pt.Sonipat utility p pt.
Sonipat utility p pt.9215811330
 
рекомендации по презентации
рекомендации по презентациирекомендации по презентации
рекомендации по презентацииMeritSirus
 
Dian suprihatin pgmi vi-a
Dian suprihatin pgmi vi-aDian suprihatin pgmi vi-a
Dian suprihatin pgmi vi-aEva Zen
 
Md M Khan Professional Profile
Md M Khan Professional ProfileMd M Khan Professional Profile
Md M Khan Professional ProfileMd Khan
 
Sprint demo 2 tws 100811
Sprint demo  2   tws 100811Sprint demo  2   tws 100811
Sprint demo 2 tws 100811twman55
 

Destacado (20)

Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013
Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013
Becoming a Command Line Expert with the AWS CLI (TLS304) | AWS re:Invent 2013
 
(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014
(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014
(DEV301) Advanced Usage of the AWS CLI | AWS re:Invent 2014
 
(DEV301) Automating AWS with the AWS CLI
(DEV301) Automating AWS with the AWS CLI(DEV301) Automating AWS with the AWS CLI
(DEV301) Automating AWS with the AWS CLI
 
Retailin france 2011_kh
Retailin france 2011_khRetailin france 2011_kh
Retailin france 2011_kh
 
Nait
NaitNait
Nait
 
Hongkong
HongkongHongkong
Hongkong
 
Natural treasure
Natural treasureNatural treasure
Natural treasure
 
Ghosts of gone birds the brief
Ghosts of gone birds the briefGhosts of gone birds the brief
Ghosts of gone birds the brief
 
Slide blog
Slide blogSlide blog
Slide blog
 
Restaurant 7 Portes in "La Vanguardia" neswpaper
Restaurant 7 Portes in "La Vanguardia" neswpaperRestaurant 7 Portes in "La Vanguardia" neswpaper
Restaurant 7 Portes in "La Vanguardia" neswpaper
 
Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)
Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)
Евгения Миронова. Ювелирный кейс «Beren Gold» (Бишкек)
 
Sheridan college
Sheridan collegeSheridan college
Sheridan college
 
Technology & Education
Technology & EducationTechnology & Education
Technology & Education
 
Sonipat utility p pt.
Sonipat utility p pt.Sonipat utility p pt.
Sonipat utility p pt.
 
рекомендации по презентации
рекомендации по презентациирекомендации по презентации
рекомендации по презентации
 
Dian suprihatin pgmi vi-a
Dian suprihatin pgmi vi-aDian suprihatin pgmi vi-a
Dian suprihatin pgmi vi-a
 
Etemplate
EtemplateEtemplate
Etemplate
 
Jodhpur media
Jodhpur mediaJodhpur media
Jodhpur media
 
Md M Khan Professional Profile
Md M Khan Professional ProfileMd M Khan Professional Profile
Md M Khan Professional Profile
 
Sprint demo 2 tws 100811
Sprint demo  2   tws 100811Sprint demo  2   tws 100811
Sprint demo 2 tws 100811
 

Similar a GUIDE - Migrating AWS EBS backed AMI's between Regions

Part 4 Scripting and Virtualization (due Week 7)Objectives1. .docx
Part 4 Scripting and Virtualization (due Week 7)Objectives1. .docxPart 4 Scripting and Virtualization (due Week 7)Objectives1. .docx
Part 4 Scripting and Virtualization (due Week 7)Objectives1. .docxkarlhennesey
 
How to Create instance in aws
How to Create instance in aws How to Create instance in aws
How to Create instance in aws Mohan Reddy
 
Adding System Call to Kernel
Adding System Call to KernelAdding System Call to Kernel
Adding System Call to KernelMuhammad Bilal
 
Getting instantly up and running with Docker and Symfony
Getting instantly up and running with Docker and SymfonyGetting instantly up and running with Docker and Symfony
Getting instantly up and running with Docker and SymfonyAndré Rømcke
 
Moving Drupal to the Cloud
Moving Drupal to the CloudMoving Drupal to the Cloud
Moving Drupal to the CloudAri Davidow
 
aosp_crave_tutorial-3.pdfhasudshsuajdhkhh
aosp_crave_tutorial-3.pdfhasudshsuajdhkhhaosp_crave_tutorial-3.pdfhasudshsuajdhkhh
aosp_crave_tutorial-3.pdfhasudshsuajdhkhhahmadsubqi1
 
Installing symfony within netbeans and WAMP
Installing symfony within netbeans and WAMPInstalling symfony within netbeans and WAMP
Installing symfony within netbeans and WAMPRiyad Bin Zaman
 
Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11Yury Pliashkou
 
Dru lavigne servers-tutorial
Dru lavigne servers-tutorialDru lavigne servers-tutorial
Dru lavigne servers-tutorialDru Lavigne
 
maXbox starter46 work with Wine
maXbox starter46 work with WinemaXbox starter46 work with Wine
maXbox starter46 work with WineMax Kleiner
 
Node.js basics
Node.js basicsNode.js basics
Node.js basicsBen Lin
 
Penetration Testing for Easy RM to MP3 Converter Application and Post Exploit
Penetration Testing for Easy RM to MP3 Converter Application and Post ExploitPenetration Testing for Easy RM to MP3 Converter Application and Post Exploit
Penetration Testing for Easy RM to MP3 Converter Application and Post ExploitJongWon Kim
 
Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)
Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)
Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)Nicolas Brousse
 
DevOpsDays Amsterdam Cosmic workshop
DevOpsDays Amsterdam Cosmic workshopDevOpsDays Amsterdam Cosmic workshop
DevOpsDays Amsterdam Cosmic workshopRemi Bergsma
 
Installing WordPress on AWS
Installing WordPress on AWSInstalling WordPress on AWS
Installing WordPress on AWSManish Jain
 
AWS Lambda from the trenches
AWS Lambda from the trenchesAWS Lambda from the trenches
AWS Lambda from the trenchesYan Cui
 

Similar a GUIDE - Migrating AWS EBS backed AMI's between Regions (20)

Part 4 Scripting and Virtualization (due Week 7)Objectives1. .docx
Part 4 Scripting and Virtualization (due Week 7)Objectives1. .docxPart 4 Scripting and Virtualization (due Week 7)Objectives1. .docx
Part 4 Scripting and Virtualization (due Week 7)Objectives1. .docx
 
How to Create instance in aws
How to Create instance in aws How to Create instance in aws
How to Create instance in aws
 
Adding System Call to Kernel
Adding System Call to KernelAdding System Call to Kernel
Adding System Call to Kernel
 
Getting instantly up and running with Docker and Symfony
Getting instantly up and running with Docker and SymfonyGetting instantly up and running with Docker and Symfony
Getting instantly up and running with Docker and Symfony
 
Moving Drupal to the Cloud
Moving Drupal to the CloudMoving Drupal to the Cloud
Moving Drupal to the Cloud
 
aosp_crave_tutorial-3.pdfhasudshsuajdhkhh
aosp_crave_tutorial-3.pdfhasudshsuajdhkhhaosp_crave_tutorial-3.pdfhasudshsuajdhkhh
aosp_crave_tutorial-3.pdfhasudshsuajdhkhh
 
Installing symfony within netbeans and WAMP
Installing symfony within netbeans and WAMPInstalling symfony within netbeans and WAMP
Installing symfony within netbeans and WAMP
 
Aws setup
Aws setupAws setup
Aws setup
 
Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11
 
Dru lavigne servers-tutorial
Dru lavigne servers-tutorialDru lavigne servers-tutorial
Dru lavigne servers-tutorial
 
maXbox starter46 work with Wine
maXbox starter46 work with WinemaXbox starter46 work with Wine
maXbox starter46 work with Wine
 
Howto Pxeboot
Howto PxebootHowto Pxeboot
Howto Pxeboot
 
Node.js basics
Node.js basicsNode.js basics
Node.js basics
 
MDT Step public
MDT Step publicMDT Step public
MDT Step public
 
Amazon ec2
Amazon ec2Amazon ec2
Amazon ec2
 
Penetration Testing for Easy RM to MP3 Converter Application and Post Exploit
Penetration Testing for Easy RM to MP3 Converter Application and Post ExploitPenetration Testing for Easy RM to MP3 Converter Application and Post Exploit
Penetration Testing for Easy RM to MP3 Converter Application and Post Exploit
 
Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)
Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)
Scaling on EC2 in a fast-paced environment (LISA'11 - Full Paper)
 
DevOpsDays Amsterdam Cosmic workshop
DevOpsDays Amsterdam Cosmic workshopDevOpsDays Amsterdam Cosmic workshop
DevOpsDays Amsterdam Cosmic workshop
 
Installing WordPress on AWS
Installing WordPress on AWSInstalling WordPress on AWS
Installing WordPress on AWS
 
AWS Lambda from the trenches
AWS Lambda from the trenchesAWS Lambda from the trenches
AWS Lambda from the trenches
 

Último

Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 

Último (20)

Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 

GUIDE - Migrating AWS EBS backed AMI's between Regions

  • 1. Migrating AWS instances between regions<br />This paper describes the process for migrating AWS running instances between regions. There are various combinations that apply to this process such as:<br />Migrating EBS AMI’s between regions<br />Migrating EBS Snapshots between regions<br />Migrating EBS Volumes on running instances between regions<br />Migrating running AWS instances between regions<br />The process<br />In each of the above scenarios, the main starting point is to have an EBS volume to work with. Once this is achieved the process is mostly the same. This paper will focus on scenario 1 in the above list. Scenarios 2 – 4 are pretty straight forward once you understand the basic process for scenario 1.<br />For this paper we will be migrating an AMI in US-EAST to an AMI in US-WEST<br />Step 1 – Starting with an AMI in US-EAST<br />The AMI we will be starting with is a Fedora AMI based on Fedora 64bit, in the image below you can see it labeled 193564345407/migrate_me_src:<br />EBS AMI<br />Identify the AMI-id of the AMI and then select the list of EBS snapshots. The snapshot that is used as the basis for the AMI will be labeled in the Description colum as Created by CreateImage (IMAGE-id) for AMI-id from vol-id. The AMI-id is what you will be looking for to match to the AMI-id of the AMI you are migrating:<br />Finding the AMI-id<br />Step 2 – Create a Volume from the AMI Root snapshot<br />Once you have identified the root volume snapshot for the AMI, the next thing you will need to do is create a Volume from the snapshot. The easiest way to do this is to right click directly on the snapshot and select create volume.<br />Creating a volume from a snapshot<br />Once you have created the new Volume it is a good idea to set the Name Tag so that you can recognize it easily.<br />Step 3 – Mount the volume on a running EC2 instance<br />Now that you have a Volume ready to go, the next step is to mount it onto a running EC2 instance. The easiest way to do this is to start up a Micro instance specifically for the job, then destroy it afterwards. <br />So go ahead and start up a Micro instance, and attach the Volume from the previous step to /dev/sdf on the new instance.<br />Remember to start up the Micro instance in the same availability zone as the Volume created in the previous step or you won’t be able to attach it!<br />Step 4 – Configure a receiving instance in the destination region<br />Now that we have the source region configured and ready to go we need to set up the destination region. To do this we will need to set up another Micro EC2 instance with a blank Volume attached to /dev/sdf of the same size as the source volume.<br />So go ahead and create a new blank Volume in the destination region and attach it to a new Micro EC2 instance. <br />When you create the new Micro instance in the destination region, create a new Key Pair just for this instance, as we will be copying the private key to the source server in the next step.<br />New EC2 instance in the destination region<br />Step 5 – Copy the private key to the source server<br />Now that we have the desination server running, the next step is to copy the private key used to start the server across to the /tmp directory on the source server. The easiest way to do this is as follows:<br />Right click the source EC2 instance and select Connect to Server option and copy this command.<br />Select Connect on the source server<br />Copy the ssh command:<br />Copying the ssh command<br />On your own laptop or computer, change directory to the directory where you saved your new private key and paste the same command but make the following changes.<br />ssh -i ping-us-east.pem root@ec2-50-19-5-173.compute-1.amazonaws.com<br />to<br />scp -i ping-us-east.pem ping-us-west.pem root@ec2-50-19-5-173.compute-1.amazonaws.com:/tmp<br />This command will use the private key of the source server (ping-us-east.pem) to allow scp (a secure copy program) to connect and copy the private key (ping-us-west.pem) of the destination server to the source server’s /tmp directory.<br />This example assumes that you have a mac or unix laptop or PC, to execute the scp command under windows you will need to download a windows scp tool.<br />Copying up the private key to the source server<br />Step 6 – Copy the volume contents from the source server to the destination server.<br />This step is the most time consuming step of the process and involves actually copying the data between the two volumes in the separate regions.<br />The visual process for copying the data is as follows:<br />Process for copying data between regions<br />Log onto the source server and run the following commands (making sure you change the key pair name and the name of the destination server)<br />$> cd /tmp <br />$> dd if=/dev/sdf |gzip -c -1 | ssh -i ping-us-west.pem root@ec2-50-18-32-121.us-west-1.compute.amazonaws.com quot; gunzip -c -1 | dd of=/dev/sdfquot; <br />To break this command down the steps are:<br />dd reads /dev/sdf on the source machine (dd if=/dev/sdf) and sends the result to std out.<br />gzip reads from std in and sends the compressed output to std out<br />ssh reads from std in and pipes the data over the wire to the following command on the destination machine: quot; gunzip -c -1 | dd of=/dev/sdfquot; <br />gunzip on the destination machine reads from std in (ssh) and sends the uncompress output to std out.<br />dd reads from std in and writes the output to /dev/sdf<br />The copy process takes about an hour between US-EAST and US-WEST, although I would expect it to take much longer between the other regions.<br />One of the great reasons for doing it this way is that you don’t mount the volume on either the source or the destination server from the operating system, and there is no file system creation required on the destination volume.<br />Step 7 – Create an AMI in the destination region<br />To create an AMI in the destination region you will need to do two steps:<br />Create a snapshot of the volume we just populated with data<br />Create an AMI from the snapshot<br />To create a snapshot, once again it is just a matter of identifying the correct volume in the EBS volumes manage and right click Create Snapshot.<br />Creating a snapshot from a volume<br />Once the snapshot has been created, identify it in the EBS Snapshots. <br />Right click on the snapshot and select Create Image from Snapshot.<br />Creating an image from a snapshot<br />Once you have selected this option the following dialog will be presented:<br />Create snapshot dialog<br />Make sure you select the same architecture type as the original AMI, (in this case the original AMI was fedora 64 bit), and give it a name. you should be able to use the default options for the rest.<br />It may be that you were using an older AMI in the source region or that the Kernel ID or Ramdisk ID’s don’t work. In this case I would recommend starting up an existing AMI in the destination region that is as close as you can get to your existing AMI and copying the Ramdisk ID and Kernel ID’s from the running instance<br />That’s it!<br />Your new AMI should now be available:<br />New AMI<br />Summary<br />In this paper we looked at the process for copying an EBS backed AMI between regions. The process used was a generic process and can be used for not only copying AMI’s between regions, but for copying generic EBS backed volumes.<br />