Ubuntu 10.04
Sponsored Link

Enable root user
2010/07/18
  The root user in Ubuntu is disabled by default because password is not set. But if you'd like to use root user by some reason, enable it.

[1] Set root password
lucid@ubuntu:~$
sudo passwd root

Enter new UNIX password:
# set root password

Retype new UNIX password:
# verify

passwd: password updated successfully
lucid@ubuntu:~$
su -

Password:
# root password

root@ubuntu:~#
# just switched to root

* The examples on this site show as a root user from now. If you use sudo, add "sudo" at the head of commands.

[2] If you enable roo, limit users to switch to root.
root@ubuntu:~#
vi /etc/pam.d/su


# line 15: uncomment and add a group that can switch to root

auth   required   pam_wheel.so  
group=adm


root@ubuntu:~#
vi /etc/group


# line 5: add users you allow to switch to root

adm:x:4:
lucid

Matched Content
 
Tweet