How to restore an EBS based Amazon EC2 Windows instance from a snapshot

This mail showed up this afternoon within my inbox:

Dear REINER SADDEY,

Your volume experienced a failure due to multiple failures of the underlying hardware components and we were unable to recover it.
Although EBS volumes are designed for reliability, backed by multiple physical drives, we are still exposed to durability risks caused by concurrent hardware failures of multiple components, before our systems are able to restore the redundancy. We publish our durability expectations on the EBS detail page here (http://aws.amazon.com/ebs).
Sincerely,
EBS Support

While it might raise your pulse, it didn’t raise mine: It’s now been just two weeks after having set up an Amazon EC2 instance – for the very first time in my life and mainly just for wetting my feet.  72 instance hours in total.

I thus considered the failure both an important warning and a welcome opportunity to practice how to restore an EBS based EC2 instance.

Starting to google for this particular task, I soon suspected it to be a c(o)urse of frustration: From next-to-impossible to contradicting statements and stories (you must create an Ami, no, you have to launch a new instance, this only works for Linux, a.s.o.), anything can be found, but no definite, convincing and authoritative recipe for restoring a Windows EC2 instance from a snapshot.

After having made up my mind to abandon further outside help, I chose to proceed exactly as I would like a restore to be performed in the first place. This is what worked for me targeting a single volume (boot-only) instance:

  1. Detached the failing volume from the EC2 instance
  2. Deleted the failing volume
  3. Created a new volume (within the same availability zone as my EC2 instance) from my snapshot
  4. Attached this volume to the EC2 instance using device name /dev/sda1
  5. Started the instance
  6. Retrieved my Administrator password (the cryptic one, must have changed it after taking the snapshot)

After having logged-in using RDP, I found all and everything exactly the same as at the time the snapshot was taken 🙂

About Reiner

Born 1954 in Ratisbon (Bavaria, Germany), in 1976 punched cards at Berlin Technical University, caught hacking one of its mainframes by Horst Zuse (son of Konrad Zuse), started studying computer science and soon was offered a job whithin their computer department doing systems programming for IBM VM/370. While studying, jobbed around Germany at various places doing all sorts of things, then returned to Berlin to work at SRZ (computer aided typesetting). Never finished my master degree, but chose to take up self-employed work (which didn't turn me rich nor famous). Now working for a mid-sized software company within a very promising department as head of server software development.
This entry was posted in at other Locations, Computers, English and tagged , , . Bookmark the permalink.

2 Responses to How to restore an EBS based Amazon EC2 Windows instance from a snapshot

  1. Richard Hancock says:

    Thanks for this simple solution that I also had not found documented anywhere else.

    Like

  2. M says:

    Thanks, this worked for me. I had the same frustrating experience of following a number of articles that left out key information like this process will only work for linux.

    One thing I noticed was the admin password was for the previous instance. I couldn’t simply get a password for the new instance I created.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s