Al usar AWS re:Post, aceptas las AWS re:Post Términos de uso

i want to move ami

0

HI team, i want to move ami to s3 bucket then is it possible to delete ami in ami creation if i want to launch ami in future whether is it possible to relaunch the ami from s3 bucket pls suggest me on this

preguntada hace un mes46 visualizaciones
4 Respuestas
1
profile picture
EXPERTO
respondido hace un mes
0

i Have lot of ami's in my aws ec2 ami portal i want to move some of the ami to s3 bucket after moving to s3 bucket if i delete ami snapshot if it is possible to retrieve the ami through bucket

respondido hace un mes
0

Please note that you can store an Amazon Machine Image (AMI) in an Amazon S3 bucket, and then restore it from the S3 bucket. The supported APIs for storing and restoring an AMI using S3 are CreateStoreImageTask, DescribeStoreImageTasks, and CreateRestoreImageTask.

Currently the store and restore APIs are only supported by using the AWS Command Line Interface, AWS SDKs, and Amazon EC2 API. You can’t store and restore an AMI using the Amazon EC2 console. Hence, please make sure that you have AWS CLI installed and updated to the latest version.

You can refer the section "Store an AMI in an S3 bucket" in the below documentation:

[+] https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ami-store-restore.html#how-it-works

The limitations and IAM permissions required are also provided in the documentation. For your convenience, please refer the steps below:

  1. Store an AMI in an S3 bucket: you have to specify the ID of the AMI and the name of the S3 bucket in which to store the AMI:
aws ec2 create-store-image-task \
    --image-id ami-1234567890abcdef0 \
    --bucket myamibucket
  1. Describe the progress of an AMI store task:
aws ec2 describe-store-image-tasks
  1. Restore an AMI from an S3 bucket: you have to specify the object key of the AMI and the name of the S3 bucket to which the AMI was copied
aws ec2 create-restore-image-task \
    --object-key ami-1234567890abcdef0.bin \
    --bucket myamibucket \
    --name "New AMI Name"

The CreateStoreImageTask API stores an AMI as a single object in an S3 bucket.

The API creates a task that reads all of the data from the AMI and its snapshots, and then uses an S3 multipart upload to store the data in an S3 object. The API takes all of the components of the AMI, including most of the non-Region-specific AMI metadata, and all the EBS snapshots contained in the AMI, and packs them into a single object in S3. The data is compressed as part of the upload process to reduce the amount of space used in S3, so the object in S3 might be smaller than the sum of the sizes of the snapshots in the AMI.

The object in S3 has the same ID as the AMI, but with a .bin extension. The time it takes to complete the task depends on the size of the AMI.

AWS
respondido hace un mes
-1

AMIs are stored in a S3 bucket you cannot see so what you are trying to do is not possible.

respondido hace un mes

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas