EC2 VM Import/Export

Kalpana Kanade
Petabytz
Published in
4 min readSep 14, 2019
  • EC2 VM Import/Export enables importing virtual machine (VM) images from existing virtualization environment to EC2, and then export them back
  • EC2 VM Import/Export enables migration of applications and workloads to EC2,coping VM image catalog to EC2, or create a repository of VM images for backup and disaster recovery to leverage previous investments in building VMs by migrating your VMs to EC2.
  • The supported file formats are: VMware ESX VMDK images, Citrix Xen VHD images, Microsoft Hyper-V VHD images, and RAW images
  • For VMware vSphere, AWS Connector for vCenter can be used to export a VM from VMware and import it into Amazon EC2
  • For Microsoft Systems Center, AWS Systems Manager for Microsoft SCVMM can be used to import Windows VMs from SCVMM to EC2

EC2 VM Import/Export features

  • ability to import a VM from a virtualization environment to EC2 as an Amazon Machine Image (AMI), which can be used to launch an EC2 instance
  • ability to import a VM from a virtualization environment to EC2 as an EC2 instance, which is initially in a stopped state. AMI can be created from it
  • ability to export a VM that was previously imported from the virtualization environment
  • ability to import disks as Amazon EBS snapshots.

Implementing Migration using Import/ Export method

You will be migrating an on-premise Virtual OS running on VMWare to AWS using Import/Export (AWS Direct Connect) method.

Pre-requisite

  1. VMware Workstation installed on your Local Machine
  2. Running AWS Account
  3. Created IAM User On AWS
  4. AWS CLI Configured On Your Local Machine
  5. Created S3 Bucket on AWS

1. Create a .vmdk export file for Ubuntu 14.04.

2. Download & configure AWS CLI.

3. Create an IAM User.

Now click on “Add User”.

Next, select a unique User name.

Now give Administrator access.

Click on Create User.

4. Create an S3 bucket and add file(image file of the OS).

Select a unique Username.

Review and Create Bucket.

Add the exported .vmdk file.

Click on Upload.

Wait till the image reflect on the list.

5. You can upload the file using AWS CLI also.

6. Once the file is uploaded, create an AMI for the imported image file.

Your image is now available as an AMI.

7. You can run the AMI created in two ways:-
(a). Using CMDER :
Copy the connection string and paste it to the CMDER Console, it will take few minutes to connect and then will open your Ubuntu 14.04. 7 (b). Using (b).Putty :
Configure the .pem file to your Putty and provide the username and the connection string. It will show initializing and few minutes later you will land on to Ubuntu 14.04.

--

--