29.12.2013 Views

l-migrate2cloud-1-pd..

l-migrate2cloud-1-pd..

l-migrate2cloud-1-pd..

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

developerWorks®<br />

ibm.com/developerWorks<br />

The Amazon EC2 service allows you to pay for a virtual machine (VM) by the hour.<br />

Amazon offers several different types of machines and classifies them by their CPU,<br />

memory, and disk profiles. Amazon measures memory and disk in terms of<br />

gigabytes and CPU in terms of Amazon EC2 Compute Units (ECU), where 1 ECU is<br />

roughly a 1.0 to 1.2GHz AMD Opteron or Intel® Xeon® processor (2007 era). For<br />

example, the standard small instance gives you 1.7GB of memory, 160GB of disk<br />

space, and 1 ECU of CPU. At the time of this writing, the biggest machine is the<br />

High-memory Quadruple Extra Large, which has 68.4GB of memory, 1.7TB of disk<br />

space, and 26 ECUs split across eight virtual cores. The prices range from US 8.5<br />

cents per hour for the smallest to US$2.40 per hour for the biggest.<br />

An Amazon EC2 instance begins life as an Amazon Machine Image (AMI), which is<br />

a template you use to build any number of VMs. Amazon publishes some AMIs, and<br />

you can make your own and share them with others. Some of these user-created<br />

AMIs are available at no cost; some incur an hourly charge on top of the Amazon<br />

hourly charge. For example, IBM publishes several paid AMIs that let you pay for<br />

licensing on an hourly basis.<br />

When you want to boot a VM, you choose the machine type and an AMI. The AMI is<br />

stored in Amazon S3 and copied to the root partition of your VM when you launch<br />

the instance. The root partition is always 10GB. The storage space associated with<br />

the machine type is called the instance storage or ephemeral storage and is<br />

presented to your VM as a separate drive. The storage is called ephemeral, because<br />

when you shut down your instance, the information is gone forever. You are required<br />

to back up your own data periodically to protect against loss. This also means that if<br />

the physical host running your instance crashes, your instance is shut down and the<br />

ephemeral disk is lost.<br />

The Amazon Machine Image<br />

All AMIs are assigned an identifier by Amazon, such as ami-0bbd5462. Amazon<br />

provides some public AMIs, and other people have made their own AMIs public. You<br />

can choose to start with a public AMI and make your own modifications, or you can<br />

start from scratch. Any time you make changes to the root file system of an AMI, you<br />

can save it as a new AMI, which is called re-bundling.<br />

In this series, you will be starting off with a publicly available CentOS image, though<br />

you can choose a different one. It is wise to spend some time looking through any<br />

image you use to make sure there are no extra accounts and that the packages are<br />

u<strong>pd</strong>ated. It is also possible to roll your own AMI from scratch, but that is outside the<br />

scope of this article.<br />

The Amazon API<br />

All of the functionality necessary to start, stop, and use the Amazon EC2 cloud is<br />

available using a web service. Amazon publishes the specifications for the web<br />

Initial migration<br />

Trademarks<br />

© Copyright IBM Corporation 2010. All rights reserved. Page 6 of 21

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!