How To Enable Root (Super) User in Ubuntu

If you are new to Ubuntu and have been using other distros like Fedora or openSUSE before, then you may find it frustrating that when you issue the "su" command it will result to authentication failure.

By default, access to root account password is disabled in Ubuntu for added security measures. But if you really want to enable root (super) user in Ubuntu just like you can on other Linux distributions, you can do it in two ways.

One way it to set a root user password by:

$ sudo passwd root
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully

After this, you will now be able to successfully use the "su" command:

$ su -

You can always disable the root user password through this command:

$ sudo passwd -l root

The second and probably the simplest method of enabling root user in Ubuntu is by executing either of the following:

$ sudo -s


$ sudo su -

That's about it. I hope some of you out there will find this simple tip on how to enable the root (super) user in Ubuntu useful.


  1. "sudo -s" keeps the normal user's environment variables. You may want to use "sudo -i"
    See this:

  2. "sudo su -" is also acceptable, don't you think?

  3. i been looking for this for long...... time

  4. I found this useful, tired of typing sudo every command I need to run as root.

    However in Fedora sudo is disabled and su is enabled by default. In this case how would we add a user to sudo powers?