Understanding The Root User And How to Obtain It

If you’re new to the realm of dedicated web hosting, you may suddenly be inundated with a bunch of terms with which you’re unfamiliar. Believe it or not, there’s a lot more to web hosting than just disc space, bandwidth, and hardware: The Linux operating system underneath comes with a heap of terminology you’ll have to become acquainted with, as well as many different quirks and methods that must be learned about.

Don’t sweat it, though, Grasshopper. We understand what you’re going through, and to help you out, we’ve got a guide to one of Linux’ most important aspects ready to go: If you’re confused about what the root user does, keep reading. All is revealed in full detail just after the break.

So What is Root?

Just as a plant has foliage and flowers at the top, so does it have roots that anchor it beneath the surface. Linux operates in the same way, allowing users to perform surface level modifications to the system at the top, while a deeper administrative user (this is the “root”) sits just below, managing all the vital organs of the operating system. Most of everything you do will be done outside the root user, but when you need to do some heavy duty file management, or install a new script, you’ll want to dip below the surface and tap into the core of things.

Why Should I Care About The Root? Do I Need It?

The root is important, because the alternative is somewhat frightening: Imagine letting all the tenants of your dedicated server have total administrative access all the time. It’s a scary though, no? Who knows what an absentminded user could accidentally do. With that in mind, root is built into your system to ensure you only mess with the foundation when you want to. It also ensures only certain people have root access, and even then, only when they need it.

How Do I Go Rooting?

It’s that easy! Other distros, like Ubuntu Server, allow access to the superuser in slightly different ways. For example, with these, there is no permanent root access, but rather a single command to type before performing a root action. This command is:

sudo

Basic SSH Commands

Here is a list of some of the more common SSH commands.

[code lang=”shell”]
<command> -h # The -h flag provides help on a command
ls # List the contents of the current directory
cd <directory or full path> # Change to that directory or path
cp <source> <destination> # Copy the source file to the destination
cp -r <source> <destination> # Copy the source directory to the destination directory
mv <source> <destination> # Move the source file to the destination
mkdir <directory name> # Create a new directory
pico <file> # Edit file in a friendly, easy to use file editor
grep <text> <file> # Search for text within a file
wget <URI> # Download the file at the given URI to the current path
tar -xz -f <file> # Un-gzip and un-tar the given *.tgz or *.tar.gz file
rm <file> # Delete the file
rm -r <directory> # Delete the directory and all contents
killall <program name> # Kill all running processes of the program
ps # Show running processes
top # Show running processes in a graphical frontend
netstat # Show all current network connections
du # Show disk usage
[/code]

We are an independently owned research and review service, funded by people like you. In the spirit of full disclosure, we get paid a referral commission when you buy digital goods following some of our links. Learn more