- Ivy Wigmore
What is Amazon Machine Image (AMI)?
An Amazon Machine Image (AMI) is amaster imagefor creating virtual servers – known asEC2Instances -- in the Amazon Web Services (AWS) Surroundings.
The machine images are like templates configured with an operating system and other software that determine the user's operating environment. AMI types are categorized by region, operating system, system architecture - 32- or 64-bit - launch permissions, and whether they are supported by Amazon Elastic Block Store (EBS) or supported by the instance store.
Each AMI includes a template for the rootVolumerequired for a specific instance type. A typical example might include an operating system, an application server, and applications. Permissions are also controlled to ensure AMI launches are restricted to the appropriate AWS accounts. Block device mapping ensures that the correct volumes are attached to the launched instance.
How to create an AMI from an Amazon EC2 instance
With an Amazon EC2 instance, AMIs can be created from running or stopped instances.
- To create an AMI from a running instance, users open the Amazon EC2 Instances view and right-click the instance's file to select itcreate imagefrom the drop down menu.
- After the selectioncreate imagefrom the drop-down menu, a pop-up appears with fields that require information, such as: B. Name and Description. After filling out the field information, selectcreate imageat the bottom of the window. Amazon EC2 automatically shuts down the instance, takes a snapshot of all attached volumes, creates and registers the AMI, and then reboots the instance. optional,No rebootcan be selected to prevent the instance from shutting down.
- Creating the AMI may take a few minutes. When the creation process is complete, the AMI appears in the AMIs view in AWS Explorer. To access the AWS Explorer view, double-click Amazon EC2 | AMIs node. View AMIs by selectingBelongs to meof theTo suedrop-down list. There is aUpdatebutton to see if the AMI has appeared; Eventually, if it appears in a pending state, it will become available.
Search for an AMI
Once an AMI is created and registered, it can be used to launch a new oneinstances. It is also possible to launch instances of AMIs that are not owned by a user if launch permissions are granted by the AMI owners. An AMI can be copied to the same or different AWS Regions, which are the locations where AWS is available. Users can find an AMI suitable for their instance, either provided by AWS, the user community, or through the AWS CLI.
AMIs can be selected based on the following factors:
- Region.Users can specify in which region they want to search for an AMI among EC2 locations around the world. Locations fall into the categories of Regions (geographical area), Availability Zones (isolated locations within a region), Local Zones,AWS Outpostand wavelength zones. Resources can be placed in local zones to be closer to the end user. AWS Outposts bring any AWS service to data centers or on-premises facilities. Finally, Wavelength Zones can host applications that offer low latencies required for communication5GDevices.
- Operating system.Users can select an AMI image by specifying an operating system, e.gLinux.
- Architecture.The AMI architecture is either 32-bit or 64-bit depending on the underlying operating system.
- launch permissions.An owner decides on permission to launch an AMI, which can be public (any AWS account can be granted access), explicit (the owner of the AMI grants specific permission to AWS accounts), or implicit (only the owner has permission to launch the AMI to start). .
- Storage for the root device.Storage for AMIs is provided either by Amazon Elastic Block Store (EBS) or by an instance store volume created from a template stored in Amazon S3.
Amazon Linux AMI virtualization types
AWS uses both paravirtualization (PV) and virtual hardware machines (HVM).
- paravirtualization.This is a virtualization technique that can improve the performance ofguest operating systemsby eliminating the hassle of emulating hardware and leveraging knowledge of the guest operating system (operating system). It is an approach to virtualization that is effective for high-performance computing (HPC) Applications such as those used for scientific computing, transactional databases, and other enterprise data processing that require fast processing. PV requires close cooperation between the Virtual Machine Monitor and the guest operating system, as well as a modified operating system kernel.
- Virtual Hardware Machines.HVMGuestsare fully virtualized and the underlying hardware must be emulated for guest use. PV modifies the guest operating system to run without this emulation. HVM requires the host computer to have a specific feature on its hardware, while PV requires the guest OS to have a specific feature in software.
While both HVM and PV machines are virtual machines (VMs), the main difference is that PV virtual machines are lightweight compared to their HVM counterparts. This means a PV VM boots faster and uses less computing hardware, but is limited to a smaller set of operating systems.
Buying, selling and deregistering AMIs
After an AMI is created, it can be kept private so that only the owner can or can use it
shared with specific AWS accounts. AMIs can also be made public to share with the community. Use of a shared AMI is at the user's risk, as Amazon cannot guarantee the integrity or security of publicly shared AMIs owned by Amazon EC2 users. Shared AMIs should be treated as any other third party code provided, meaning that the user is expected to do their own due diligence before using a publicly available AMI.
AMIs can also be purchased from third parties, including those that have service contracts with organizations such asroter Hut-- a Linux distribution based on the source code of the Linux kernel. AMIs that are created can also be sold to other Amazon EC2 users.
When an AMI is deregistered, current instances are not affected, but it cannot be used to launch new instances. Existing instances already using the AMI are not affected and instance charges will continue to apply. This means that when a user is done with an instance, it should be terminated.
This was last updated inJune 2021
Read more about Amazon Machine Image (AMI)
- Amazon Linux Container Image On Premises is still all about the cloud
- Amazon Machine Images: HVM oder PV?
- Manually booting up an EC2 server instance in 7 steps
- Best practices for creating and using Amazon EC2 instances
- AWS Partner Network (APN)
- The Amazon Web Services (AWS) Partner Network (APN) is an AWS-supported classification for a global community of cloud services...See full definition
- computer system
- A computer system consists of hardware components, carefully chosen to work well together, and software...See full definition
- virtual server
- A virtual server, also known as a virtual machine (VM), is a partitioned space within a real server and is transparent to users,...See full definition
Dive deeper into AWS infrastructure
- How to Create an EC2 Instance Using PowerShellBy: AnthonyHowell
- How to launch an EC2 instance with TerraformBy: MichaelLevan
- Steps to Launch an EC2 Instance Using AWS CloudFormationBy: ErnestoMarquez
- Use the AWS CLI to create an EC2 instanceBy: ErnestoMarquez