Possible Duplicate:
How to know my root password?
I'd like to define a password for root so that I can use su
directly, without having to prepend it with sudo
. And because I'd like to log in as root as well.
So how to set a password for the root user?
You may have noticed that you can’t log in as root on Ubuntu, this is because root doesn’t actually have a password set.
Enter the following command:
You will be prompted for your current user's password, followed by the password you want to set for root. The messages prompted should be similar to the following:
The following message will appear after that:
If the above message showed up on your terminal, you can now enter as root from your current user entering the following command:
And you will be prompted for the root password you've set. That's it!
If you still want to use
su
after reading the warnings in the question, there is no need to set a root password. Just dosudo su
and you're on your way with your regular password.What I do to create the root on ubuntu: first I do this
then
as @Zignd mentioned the classical messages will appear:
then I can use the
su
as a normal root acount...