Friday, October 22, 2010

How to rebundle Ubuntu 10.10 (Maverick Meerkat) EBS root

There was a post on the ec2ubuntu list regarding a problem the poster had with re-bundling a Ubuntu 10.10 instance. The poster followed another blog entry. I responded to the post, but figured that a blog entry might reach a larger audience.

The simple summary of my long winded post is this:
    To rebundle an EBS root image, use ec2-create-image.

If you've launched one of the Official Ubuntu 10.10 Images and modified it a bit, the best way to create a new AMI with the modifications in it is to:

1.) stop the instance (do not terminate it)
2.) "create-image"
3.) wait for your new AMI to become available and run your new instance

Note, that all of the above steps can be done from the EC2 console as well as by using the command line tools. I don't think I previously realised how nice this api call is.

The reason that the title of this post includes 'Ubuntu 10.10' rather than just "Ubuntu", is that releases of 10.04 and earlier do not utilize pv-grub. If you're re-bundling one of those images, you have to take additional steps to get a new kernel upgrade. You really should take those steps, as kernel upgrades include important security fixes, and newly created AMIs should always be created with the most recent kernel available.


  1. Is there a way to do this with an S3 backed instance? My 10.10 rebundled instances won't boot due to pvgrub issues.

  2. @ezwrighter,
    This recently came up on the ec2ubuntu forum, and I've posted some instructions on how to fix the issue there. Please read the thread at [1]. This is something that I should either blog about or fix the issues in 11.04 and SRU to maverick.


  3. Thanks! This did the trick. Instead of creating a new image, I just changed the instance type to small and then back. All can be done in the web console.