Skip to content

[Safely] Update an Ubuntu EC2 instance on Amazon AWS

Ubuntu 12.04.1 LTS was released and that meant it was time to upgrade my Ubuntu EC2 instances from 11.10 to 12.04.1 LTS.

When I logged in via SSH I saw the nag “do-release-upgrade” and thought, “crap…the last time I did this, I blew up my server”. After doing a few Google searches, the light bulb came on and I thought, “Duh!”

First, create an Amazon Image (AMI) of your existing server. This creates a fully functional carbon copy of your current instance, which can be launched and deployed at will.

When it’s finished, go ahead with the upgrade:

sudo do-release-upgrade

If anything fails, you can simply launch the newly created AMI and re-associate your Elastic IP. (You ARE using an Elastic IP right?)

BTW: The upgrade from Ubuntu 11.10 to 12.04.1 LTS went flawlessly, and after a few days I will delete the AMI and associated EBS volumes.

About Greg Rickaby

Director of Engineering @WebDevStudios / Author & Tech Editor @ForDummies / @WordPress Contributor / @gatsbyjs Maintainer / Follow Greg on Twitter

1 Comment

  1. Rocketship Chair on May 28, 2014 at 12:17 pm

    Thanks very much for this article.. first timer here doing the upgrade.. man is it nerve wracking..

Leave a Comment