Switching user accounts without logging in an out

Of course, there are times you absolutely have to access the super-powers of the superuser. It would be impractical to log in and out and even avoidable to use the root account this way. Those of you who have read enough cartoons, already know the solution… Superpowers are great, but many heroes also have their gadgets or tools in addition, or some might only be able to access their superpowers with the aid of some chemical compound that alters their consciousness and makes them see dragons. O wait, that is a different story… let's not even try to go there.

Now, the point is, that there is a tool, a Linux command that you can use to access these powers, called su, which stands for "substitute user". Basically, you can open a terminal, type su <username>, and if you have the given user’s password, you will be granted all the permissions and access that user has, until you exit su. This is quite useful if you need or want to do something on behalf of another user (if you have access to their account), but the su command is generally used to “impersonate” the root user account.

You do this by simply typing su and giving the root password (if you do have it, of course). Until you close the terminal windows or type exit, you will be acting as a superuser, so you can install or uninstall software, upgrade the system, etc. in practice, mostly you would never even do this though. Graphical interfaces for software installation or system updates will ask for this password and do the hard work while you sit and watch, but this is what will be happening in the background, so it’s probably best to be aware of it.