I had an instance that I could no longer find it's PEM file, so I totally freaked out and curled in a fetal position and started sobbing but then the Oracle helped me.
This post here did the trick: http://blog.celingest.com/en/2013/11/14/replace-lost-keypair-ec2-instance/
I just had to do one little change because the instance to be jacked wasn't using a EC2-USER but a ROOT user, so on this step:
cat
/home/ec2-user/
.
ssh
/authorized_keys
>
/mnt/recovery/home/ec2-user/
.
ssh
/authorized_keys
I had to change it a bit, to this:
cat
/home/ec2-user/
.
ssh
/authorized_keys
>
/mnt/recovery/root/
.
ssh
/authorized_keys
And Yippie kay-yay!
Cheers.
No comments:
Post a Comment