I frequently answer questions on Yahoo! Answers and have noticed that there’s consistantly new Ubuntu (Linux) users asking how they become the super user to run some certain command. Of course, finding the answer to this question should be extremely easy with Google and it is.
In Ubuntu, by default, the root user’s password is locked. This means that we don’t know it and we can’t always sign in as root or unfortunately use the normal linux su command either. Locking the root user’s password forces users to use the lowest needed acccess which reduces some of the ways a system can be attacked or “rooted.”
The command in ubuntu is sudo which allows programs (or commands) to run with root-level privileges.The syntax is very simple:
sudo /etc/init.d/httpd restart
In this example, I just restarted apache.
For more information, please check out the sudo man page
One response to “Becoming a Super User In Ubuntu”
Good post Brian! Thanks for the info!