Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Migrate from t1.micro to t2.micro Amazon AWS

There is no way to migrate from t1.micro to t2.micro on Amazon directly, I know it.

So, is it gonna be work:

  1. Detach EBS volume from current t1
  2. Create new t2.micro instance
  3. Attach EBS vol to the new t2

Is it safe for a data?

like image 416
Denis L Avatar asked Oct 31 '14 14:10

Denis L


1 Answers

This method is actually easier than the one on the amazon forums. It also provides a step by step procedure with images.

http://jsianes.blogspot.jp/2014/07/aws-convert-t1-instances-to-t2.html

The basic idea is to:

  1. Shutdown the t1 instance (1) and detach the volume (A)
  2. Launch a new t2 instance (2), shut it down and detach the volume (B)
  3. Use a temporary t2 instance (3), attach both volumes to it
  4. Copy B boot module somewhere and erase all contents of B
  5. Copy all the contents from A to B
  6. Copy back the boot module to B
  7. Terminate 3 and enjoy 2!

Note: If you are rebinding an Elastic IP you will need to replace the ssh keys associated with the previous host

ssh-keygen -f "/home/user/.ssh/known_hosts" -R <IP>
ssh-keygen -R <IP>
like image 133
kittikun Avatar answered Sep 30 '22 15:09

kittikun