Sunday, September 25, 2011

Fun with Ubuntu: What is Sudo?

0 comments
Since we have been posting quite a bit of information for new Ubuntu users I thought I'd cover the topic of what is 'Sudo'?  Why do we use it/need it?  What do elevated privileges allow us to do within Ubuntu?  I will try to clear this up for those who may be unfamiliar with what it means to use 'Sudo'.

Most of the time you may hear the administrative access in Linux/Unix to be limited to the 'Root' user or the 'Super User'.  But in Ubuntu, we do not have a 'Root' user.  Instead we have the 'Sudo' program.  By running a command from the Terminal using a 'Sudo' command, you are temporarily granting your user account the same access to elevated privileges as another account (in the case of sudo that account would be the Root or Super User account).  And you can even think of the command: sudo; as 'SUper user DO' to help you remember it.  Another way to remember what it means to think of the word it sounds like: pseudo.  Which means: to be like something else (in Techie's terms).  So in a sense you want your account to be a pseudo of the admin account temporarily.

You will use sudo when you attempt to install a package or remove a packages, modify system files, add repositories, update apt, install updates, etc.  Administrative tasks are usually protected by sudo access.  When using the sudo command you will be prompted in the Terminal for your password.  In most cases, this is the same as your log on password.  Unless this has been changed by the system admin.

Running a command with sudo, will grant your user account access to super user rights for 15 minutes at a time.  After 15 minutes, if you run another sudo command you will be prompted for your password again.  And easy way to think of sudo in relation to Windows Vista/7 would be think of it as the UAC of Ubuntu.  Sudo is a powerful command when used in conjunction with other strings in the Terminal.  Use it wisely and carefully.

Even though you may not use the Terminal much, most user's are fine with using the graphical user interface.  You may occasionally bump into a situation where you need to use the command line.  And it is important that you know what sudo is.  Especially when a lot of sites will post Terminal commands, but will offer very little instruction on what those commands actually do.

I will also hit the topic of 'Sudo' briefly in an upcoming video. 

0 comments: