Decreasing Root Disk Size of an "EBS Boot" AMI on EC2

Posted by darkAsPitch on Server Fault See other posts from Server Fault or by darkAsPitch
Published on 2011-11-19T06:54:43Z Indexed on 2011/11/19 9:55 UTC
Read the original article Hit count: 343

So I have followed Eric's wonderful article here: http://alestic.com/2009/12/ec2-ebs-boot-resize

This was the code basically that helped me increase the default size of the AMI:

 ec2-run-sintances ami-ID -n 1 --key keypair.pem --block-device-mapping "/dev/sda1=:250"

Running Ubuntu 11.10 I didn't even have to re-size the disk afterwards, it was immediately a 250GB drive.

How do I go about decreasing the default size of the AMI???

I tried:

 ec2-run-sintances ami-ID -n 1 --key keypair.pem --block-device-mapping "/dev/sda1=:100"

Obviously... but I was told:

Client.InvalidBlockDeviceMapping: Volume of size 100GB is smaller than snapshot ####### <250>

© Server Fault or respective owner

Related posts about amazon-ec2

Related posts about hard-drive