Get/Reset root password on a Linux EC2 instance

0

I am user accessing AWS through Okta SSO. I created a Linux EC2 instance and am accessing it using SSH with a key-pair. sudo helps most of the time but for one specific task I need root password but I don't have it (never had). Is there a way to get it or reset it?

1 個回答
1
已接受的答案

"sudo passwd root" should work.

profile pictureAWS
已回答 2 年前
profile picture
專家
已審閱 1 個月前
  • I have the same or similar problem. Not on my instance:

    [cloudshell-user@ip-10-6-67-43 ~]$ sudo passwd root sudo: passwd: command not found

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南