Vol. I · No. 46The command line sectionSat, 10 Oct 2026
The people

/root

the administrator’s home

/root is the home directory of the root user. It is not the root of the tree — that is /. It is simply where the administrator’s own files and settings are kept, and it is closed to every other user.

/ is the root directory. /root is root’s home. They are not the same.

Holds
root’s own files
Settings, history, keys
On disk
Yes
On the root filesystem
Who reads
root only
Others get “Permission denied”
Short form
~
When you are logged in as root

Why it exists

Every directory at the top of the tree is there for a reason. This is the problem /root solves.

Available when /home is not

/home is often a separate partition or a network share. If it fails to mount, root can still log in to repair the system, because root’s home is on the root filesystem.

Kept apart from ordinary users

The administrator’s keys, scripts and history are more sensitive than anyone else’s, so they are not placed beside the other home directories.

What you find inside

Not everything, but the entries worth recognising. Each is marked as a directory, a file, a link or a device.

/root
  • .bashrcfileroot’s shell settings.
  • .bash_historyfileThe commands run as root in earlier sessions.
  • .sshdirectoryKeys allowed to log in as root, and root’s own keys.
  • .profilefileCommands run at login.

At the terminal

Four commands that show what this directory is doing on a real machine.

ls /root

As an ordinary user this fails with “Permission denied” — which is the point.

sudo ls -la /root

List root’s home with root’s rights.

sudo -i

Start a shell as root. It opens in /root.

ls -ld /root

Show the permissions on the directory itself: owner only.

Handle with care

What goes wrong here, and what someone securing or attacking the machine looks at.

Do not work as root by habit

A mistake made as root has no safety net. Use your own account and sudo for the single command that needs it.

Check who may log in as root

/root/.ssh/authorized_keys lists the keys that can log in as root directly. An entry there that nobody recognises is serious.

Read alongside