Trusted answers to developer questions

How to use an AMI to create an EC2 instance

Anjana Shankar

Grokking the Behavioral Interview

Get Educative’s popular interview prep course for free.


Amazon EC2 (Elastic Compute Cloud) is an offering from AWS providing compute capacity on demand. AMI or Amazon Machine Image is a template from which an EC2 instance can be built.

Use AMI to Launch an EC2 instance

When we launch an EC2 instance, it indicates that a virtual machine is created. The AMI that we selected is copied to the root device volume. This contains the boot image. Once the instance starts, what we get is a virtual machine that we can connect to.

Typically, we’ll install further software and packages as per our needs.

Create an AMI

Once we have an instance properly configured, we can use this instance to create an AMI. This resulting AMI can then be used to start the new EC2 instance.

Choose an AMI while creating EC2


AMI Categories

There are several categories of AMIs available on the AWS console:

  1. Quick start AMIs

    These are images provided by Amazon. These can be used to get started quickly.

  2. AWS marketplace AMIs

    These are images that provide popular open-source and commercial software from third-party vendors.

  3. My AMIs

    These are created from your EC2 instances.

  4. Community AMIs

    These are provided by the user community of AWS.


Using an AMI can help us quickly get started with an EC2 instance bringing our bootstrap time close to nil.


Trusted Answers to Developer Questions

Related Tags

Keep Exploring
Related Courses