CreateImage
Description
Creates an AMI that uses an Amazon EBS root device from a "running" or "stopped" instance.
AMIs that use an Amazon EBS root device boot faster than AMIs that use instance stores. They can be up to 1 TiB in size, use storage that persists on instance failure, and can be stopped and started.
Request Parameters
Name | Description | Required |
---|---|---|
|
Type: |
Ancestor: None
Children: instanceId
, name
, description
, and noReboot
instanceId
The ID of the instance.
Type: xsd:string
Default: None
Ancestor: CreateImageType
Children: None
Yes
name
The name of the AMI that was provided during image creation.
Type: xsd:string
Default: None
Constraints: 3-128 alphanumeric characters, parenthesis (()), commas (,), slashes (/), dashes (-), or underscores(_)
Ancestor: CreateImageType
Children: None
Yes
description
The description of the AMI that was provided during image creation.
Type: xsd:string
Default: None
Constraints: Up to 255 characters
Ancestor: CreateImageType
Children: None
No
noReboot
By default this property is set to false, which means Amazon EC2 attempts to cleanly shut down the instance before image creation and reboots the instance afterwards. When set to true, Amazon EC2 does not shut down the instance before creating the image. When this option is used, file system integrity on the created image cannot be guaranteed.
Type: xsd:boolean
Default: false
Ancestor: CreateImageType
Children: None
No
Response Elements
Name | Description |
---|---|
|
Type: CreateImageResponseType Ancestor: None Children: |
|
The ID of the request. Type: xsd:string Ancestor: Children: None |
|
The ID of the AMI. Type: xsd:string Ancestor: Children: None |
Examples
Example Request
This example creates an AMI from the i-10a64379 instance.
<CreateImage xmlns="http://ec2.amazonaws.com/doc/2009-10-31/"> <instanceId>i-10a64379</instanceId> <name>fedora-v11.01</name> <description>Fedora_v11</description> <noReboot>false</noReboot> </CreateImage>
Example Response
<CreateImageResponse xmlns="http://ec2.amazonaws.com/doc/2009-10-31/"> <ImageId>ami-4fa54026</ImageId> </CreateImageResponse>