I'm asked for the root password and it doesn't match my user password.

Can anyone tell me the root password?

  • i am having this same problem. and when i try the sudo passwd or any other sudo command, my comp says "unable to change to sudoers gid:operation not permitted.. SOMEONE please helppppp
    – jaimie
    Commented Jan 17, 2017 at 14:08

3 Answers 3


According the Ubuntu documentation, you can reset your root password following these steps:

Boot your system and hold shift key pressed until you can see the GRUB screen.

Use your arrow keys to go to an option marked as "elementary OS, linux... Recovery mode". Hit enter.

You must see a new screen with some options. Select the option marked as "root". You will be prompted to a bash screen where you can see something like:


You must make your filesystem writable with the next command:

mount -rw -o remount /

Now you can change your password with the command:

passwd username 

Where username is your current user. You must enter the new password twice.

After this, you can continue with normal boot with the command:

init 2

More information at:

Ubuntu documentation

  • What are the downsides to this? Commented Jun 14, 2016 at 23:50
  • I mean is it that easy to access somebody's Linux system with physical access? Commented Jun 15, 2016 at 0:15
  • In a Ubuntu fresh installation, yes, it's so easy. Others distros ask for root password along installation process.
    – bitseater
    Commented Jun 15, 2016 at 5:01
  • So we can only do what you said in ubuntu? Commented Jun 16, 2016 at 20:38
  • I'm sorry it isn't making sense to me at all. If I do this right now on my computer will I be able to change the root password without having to put any password? Commented Jun 16, 2016 at 20:39

Elementary OS is based on Ubuntu, Ubuntu creates the root user without a password. This is a security measure as Linux does not allow anyone to log into a user account that doesn't have a password. So by default no one can log in as root. Users can run commands as root by using the sudo command, and can change to the root user using sudo su - . There is no real advantage to giving root a password on an Ubuntu system but if you want to you can simply use sudo passwd ... ie running passwd as root.

What was you trying to do when you was asked for a root password ?


Possibly you didn't set your root password.

Because you have administrative permissions from your account, you can do pretty much everything with sudo mode - you enable it with your account password.

However, root is a master account that can do everything. The whole difference is that even with sudo mode you can't mess up things as bad as you can with root (sth that they didn't think of in windows).

So if you need root password, firstly you need to set it up.

1.Open terminal 2.Type sudo passwd root 3.You'll be asked for your account's password 4.Then you choose new password for root and confirm it 5.Ta-Da! You've set root password. You can switch to root with terminal with su command.

However, From my experience, you don't need using root in linux (maybe in same cases), so consider if it's really necessary.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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