James
James

Reputation: 83

Password for ec2-user on AWS Cloud9

I am trying to run $ sudo su in the terminal of AWS Cloud9. I get prompted for the password for the ec2-user. Any ideas what this might be?

Might be worth noting that prior to coming up against this issue, when trying to yum install a package, I got 'packages excluded due to repository priority protections' so I ran yum erase yum-plugin-priorities as per https://serverfault.com/questions/312472/what-does-that-mean-packages-excluded-due-to-repository-priority-protections (I'm fairly sure I had to do that with sudo but wasn't prompted for the password).

Upvotes: 4

Views: 9455

Answers (5)

unacorn
unacorn

Reputation: 1042

i got an error when trying the sudo passwd ec2-user way saying ec2-user does not exist.

In the end i did with

sudo su -

then passwd ubuntu and set my new password when i saw Enter new UNIX password:

After set, just type exit and enter, then continue to the step earlier which encountered the require password step, i can then use the new password to continue

Upvotes: 0

yogesh cl
yogesh cl

Reputation: 771

First you need to set your password using command

$ sudo passwd ec2-user

Then you can use the new password where ever its required

Upvotes: 6

Felix
Felix

Reputation: 526

In the cloud9 (terminal) you have to change the users password with:

$ sudo passwd ec2-user
Changing password for user ec2-user.
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.

Upvotes: 1

I ran into the same problem which trying to install homebrew on my ec2@Cloud9 Env.

When requested for password, I didn't place any let the program wait for a while after which I could see the package homebrew got installed.

Upvotes: 0

SMRANGEL
SMRANGEL

Reputation: 1

Use "sudo passwd root" or "sudo passwd"

Upvotes: -3

Related Questions