Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I recently took over a rails project from another developer that uses capistrano to deploy to EC2. When I try to deploy it is asking for a password.

I can't figure out where to change the user and password in my EC2 account. I can login, but it seems that the deploy process is using a different user. The error looks like this:

connection failed for: (Net::SSH::AuthenticationFailed: stackbuilders)

"stackbuilders" is the old username. Where would I change this to my EC2 username and set up a new password?

share|improve this question
up vote 1 down vote accepted

This isn't an EC2 account username, it's the SSH credentials on the instance(s) in question. You should get this information from the previous developer, or your client.

If that isn't possible, there's a couple of options:

  • Rebuild the environment from scratch. If the instances are ephemeral, this is the only possibility.
  • If the instances are EBS-backed, you can stop them (do NOT terminate them), attach and mount the EBS root volumes on a scratch EC2 instance you've built and know the password to, and then modify the disk image to have credentials you control (edit /etc/shadow, or chuck an SSH key into the right place).

If this sounds like effort, well, welcome to being a sysadmin. And next time, get the password off the previous dev before you take the job on, or at least tack an extra few hundred clams onto the estimate for your hassle.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.