Sunday, August 25, 2013

Amazon Authentication failed. How to recovery

The problem with EC2 instance when I try to connect via SSH. Authentication failed.Permission denied
  1. Stop the running EC2 instance
  2. Detach its /dev/sda1 volume (let's call it volume A)
  3. Start new t1.micro EC2 instance, using a new key pair
  4. Attach volume A to the new micro instance, as /dev/xvdf
  5. SSH to the new micro instance and $ sudo mkdir /mnt/tmp
  6. $ mount /dev/xvdf  /mnt/tmp
  7. $ cd /mnt/tmp and copy all needed data
  8. You can try to change  keypair for you your old instance on a new
     Copy ~/.ssh/authorized_keys to /mnt/tmp/home/ubuntu/.ssh/authorized_keys
  9. Logout
  10. Terminate micro instance
  11. Detach volume A from it
  12. Attach volume A back to the main instance as /dev/sda1
  13. Start the main instance
  14. Login as before, using your new .pem file

6 comments:

  1. Nice way of offering details i wish you will be precede this making reference to of details with your guests later on also for their improvement.cloud inventory software

    ReplyDelete
  2. Nice post, thanks to share this information. It’s really helpful for the people have Amazone accounts.
    Web designing company in India

    ReplyDelete
  3. Hi! This post could not be released any better! Learning this post shows me of my old roommate! He always kept making reference to this. I will forward this material to him. Pretty certain he will have a outstanding research. Many thanks for sharing!Online accounting software

    ReplyDelete
  4. Im no expert. but I believe you just made an excellent point. You certainly fully understand what youre speaking about. and I can truly get behind that.
    att email server settings

    ReplyDelete
  5. Your blog provided us with valuable information to work with. Each & every tips of your post are awesome. Thanks a lot for sharing. Keep blogging.
    seo api

    ReplyDelete
  6. When it comes to roofing Indianapolis IN residents want their roofers to be able to do more than just roof installation. It can be tricky finding a company that handles roof repairs, maintenance, installing gutters, and siding. If you want a company that can do all of these things, then you have come to the right place. We are the roofing contractors Indianapolis always needed!




    Address: 809 Lionshead Ln, Greenwood, IN, 46143

    Phone: (317) 751-7125

    business email: newroofmadeeasy@gmail.com

    ReplyDelete