I decided that I wanted to create an EBS backed AMI on Amazon’s Cloud Computing platform.  I thought this would be REALLY hard.  I was completely wrong.

The first thing I did was start with an already existing EBS AMI. Right now there aren’t too many available but they are growing.  I chose an Ubuntu 9.04 image since I’m going to install a stack on it, and I’ve already done *most* of it before on Ubuntu.

A quick note: it is possible to create an EBS AMI from an S3 AMI, but I wasn’t able to figure that out (quickly).  Although I did find a script that will do this for you: http://gist.github.com/249915.

Next, I wanted to get the Ubuntu server prepared.  I needed to:

  • install mysql — http://www.howtogeek.com/howto/ubuntu/install-mysql-server-5-on-ubuntu/
  • install ruby on rails — http://www.hackido.com/2009/04/install-ruby-rails-on-ubuntu-904-jaunty.html (up to and including step 6)
  • install zlib — http://www.techsww.com/tutorials/libraries/zlib/installation/installing_zlib_on_ubuntu_linux.php
  • install blacklight — http://projectblacklight.org (includes solr and a number of gem dependencies)

I did all of this.  One thing I noticed, Blacklight requires me to use non-standard ports (ie not 22 and 80).  While the server was running, I went into the AWS console and opened ports for its associated security group.  The changes took effect immediately.  I definitely liked that.

Finally, I went in to the AWS Management Console and chose “Create Image (EBS AMI)”.

Picture 1

Then I filled in the information including a description of my image:

EBS AMI Details

and voila! EBS backed AMI.  the one caveat is:

DON’T TERMINATE THE INSTANCE UNTIL THE NEW AMI HAS FINISHED BEING CREATED

because then you’ll loose all the work that you have just done.  doh!