Amazon EC2 - The Difference Between Images and Volumes

By the way, I am running my LAMP server on m1.Small (runs on AMI 32bit Amazon) at the moment. (EBS)

Data on this subject Linux and its configuration (for example, Timezone) the applications that I install (for example, s3cmd, apache) "/ var / www / html" - where my website mysql data is stored After several hours of browsing the Internet and reading The guides for their use confuse me with concepts as follows. * Images 1,2,3,4 * Volumes 2,3,4? (i.e. there is no OS data in the volume)

Do I understand correctly?

So, if I want to return to a specific picture. The use of volumes. (ie it works only if they use the same AMI) 1. create a volume from a snapshot 2. disconnect the volume from the instance 3. attach the new volume created by the above process to the instance

Use of images. 1. create an image from the snapshot 2. start the instance from the image 3. associate the old elastic IP with the new instance 4. complete the old instance, etc.

I am sure that I do not understand something. Basically, what's the difference between images and volumes?

+4
source share
1 answer

Your descriptions of how to return to old copies of the system are largely correct, you just clarified the terminology a little.

An EBS volume is like a hard drive connected to your instance.

You can connect several volumes at different points of connection at the same time, as on a physical server.

One of these volumes has a root file system with the kernel of the operating system you are working on. It can also have your web pages and MySQL data, or you can configure them on a separate attached volume.

A snapshot is like a copy of a hard drive that you can use to create new hard drives (volumes) with the same content. You can take snapshots of any volume (s), root directory or data. When you create a new AMI (image), this is done using snapshots.

AMI is a snapshot of the EBS root volume, which is also specially registered so that it can be used to start new instances. A registered AMI may also refer to additional snapshots that must be copied to new volumes and attached to a new instance.

You can detach and attach non-root volumes from / to instances while they are running. You can also detach and attach EBS root volumes, but only when the instance is stopped (not normal, but sometimes useful).

The amount of data can be moved or copied between instances, even if they do not work with the same AMI.

+14
source

All Articles