> For the complete documentation index, see [llms.txt](https://karansingh.gitbook.io/aws-saa-c02/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://karansingh.gitbook.io/aws-saa-c02/ec2/amazon-machine-image-ami.md).

# Amazon Machine Image (AMI)

* An AMI **provides the information required to launch an instance**.<br>
* You **must specify an AMI when you launch an instance**.<br>
* You **can launch multiple instances from a single AMI** when you need multiple instances with the same configuration (AMI).<br>
* You are **only charged for the storage of the bits that make up your AMI**, there are **no charges for creating an AMI**.<br>
* **AMIs are tied to the Region** where its files are located with Amazon S3.
  * **For using AMI in different regions, the AMI can be copied to other regions**.

## Buying, sharing, and selling AMIs

* **After you create an AMI, you can keep it private so that only you can use it, or you can share it with a specified list of AWS accounts or sell the AMI**.<br>
* You **can also purchase AMIs from a third party**, including AMIs that come with service contracts from organizations such as Red Hat.

## Copying an AMI

* You can **copy an AMI within or across AWS Regions**.<br>
* **Copying a source AMI results in an identical but distinct target AMI with its own unique identifier**.<br>
* There are **no charges for copying an AMI**.
  * However, **standard storage and data transfer rates apply**.<br>
* You can **copy an unencrypted snapshot to make an encrypted snapshot**.
  * However, you **cannot copy an encrypted snapshot to make an unencrypted one**.

## Cross-Region copying

* It provides the following benefits:<br>
  * **Consistent global deployment**
    * Copying an AMI from one Region to another **enables you to launch consistent instances in different Regions based on the same AMI**.<br>
  * **Scalability**
    * You can **more easily design and build global applications** that **meet the needs of your users**, regardless of their location.<br>
  * **Performance**
    * You can **increase performance by distributing your application, as well as locating critical components of your application in closer proximity to your users**.<br>
  * **High availability**
    * You can **design and deploy applications across AWS Regions, to increase availability**.

## Cross-account copying

* You **can share an AMI with another AWS account**.<br>

* **Sharing an AMI does not affect the ownership of the AMI**.<br>

* The **owning account is charged for the storage in the Region**.<br>

* **If you copy an AMI that has been shared with your account, you are the owner of the target AMI in your account**.<br>

* To copy an AMI that was shared with you from another account, the **owner of the source AMI must grant you read permissions for the storage that backs the AMI**.

  * If the shared AMI has encrypted snapshots, the **owner must share the key or keys with you as well**.

* **Can't copy an AMI with an associated** `billingProduct`**, instead you have to launch the AMI first and then create an AMI from that**.
