Sign up ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I lost the password for root on a ubuntu virtual machine. Is there any way to restore it or I need to install a new virtual machine with ubuntu again?

share|improve this question

2 Answers 2

up vote 3 down vote accepted

You can change your root password by running sudo passwd root

share|improve this answer
ohhh great!!! I was desperated for an hour :-s thanks bro!!! – Hoang Pham Mar 20 '10 at 18:10

Ubuntu doesn't have a password for the root account, unless you explicitly enable it after installing. Sudo will ask for your current account's password, by default.

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.