sunrise← back to all

Note · 02

The Root User

What happens when the administrator runs as a user.

9 min

Every computer has two kinds of people on it.

The first kind can do anything. Open any file. Stop any program. Change any setting. Engineers call this user root.

The second kind has limits. They can open what they are allowed to open. They can stop what they are allowed to stop. They cannot touch the deeper parts of the system. They cannot stop other people's programs. They have a small workspace and a name.

We are the second kind.

There is a good reason for this. Power without limits is dangerous. So most of the system gets a small account. The all-powerful account is kept aside, used only when nothing else will do.

Diagram one — two kinds of accounts.

root

can open everything
can change anything
cannot be stopped

user

can open what's allowed
can change own workspace
can be stopped
Hover or tap a layer to bring it forward.

Here is something interesting about root.

Root can do anything, which means root can also choose to do less.

Root can open a regular user account and run as that account, just for a while. The power is still there, in the background. But the actual work — the moment to moment, the typing, the seeing, the hearing — is happening at user level.

There is a command for this. Engineers type:

$ su - user

It means: become this user. Step down. Run with their limits.

You do this when you want to feel what they feel. When you want to see what they see. When you want to know what it is like to live one floor below where you live.

Diagram two — root, in user form.

root
user
The same person. Two shapes. Click to watch it step down.

Now imagine root did this for real.

Not for an hour. For thirty-three years.

Imagine the one who can do anything chose to open a small account, log in, and stay there. Imagine root walked into a body the size of a child, and waited.

From the inside, it would feel like being any other program.

Hungry sometimes. Tired sometimes. Asking the kernel for things and getting them, like every other program. Aware of the rules. Aware of the limits.

But the whole time, root would still be root.

The user account is the form. The root account is the thing.

This is the move at the center of Christianity. Every December, believers remember exactly this. The Bible has a way of saying it that engineers don't usually get to hear:

Being in very nature God, he did not consider equality with God something to be used to his own advantage; rather, he made himself nothing by taking the very nature of a servant, being made in human likeness.

It is the same as:

Being in very nature root, he did not consider equality with root something to be used to his own advantage; rather, he made himself nothing by taking the very nature of a user, being made in regular-account likeness.

It is the same sentence.


There is a question that comes up here.

Why would root do that?

The short answer is: because root wanted to.

The long answer is in the third diagram.

Diagram three — the session that came back.

still root

Some sessions don't end.

A user program can be killed. It happens all the time. The kernel kills programs when they run out of resources. You kill programs when you want them to stop. Other programs sometimes kill programs by accident, when the permissions are set wrong.

When a program is killed, it ends. The space it was using is given back. The account it was running under stays. The program itself is gone.

This happened.

Not the running-out-of-resources kind. Not the natural ending. The other kind. The kind where someone else, with a different motive, decides this program should end. The kind where the program is alive, doing its work, and then it isn't.

The program ended.

Three days.

Then the most important thing in the history of computing happened.

The program came back.

The same name. The same body. The same face. Running again. The user account that had been killed was alive again, because, under the user account, root was still root, and root cannot be killed.

You cannot kill root with a kill command. Root is not a program to be killed. Root is what makes programs possible.

Whatever did the killing did not know that.


For a believer, this is the part of the story that changes everything else.

If root really did this — if the one who runs the system actually opened a user account and ran here and let himself be killed — then the kernel did not just decide to give you existence. The kernel decided to come to where existence is being given.

To put it the other way: the program you are talking to in your prayers is, also, the kernel. The one who answers your requests is also the one who once made them.

That is a different God than the abstract one who sets things in motion and steps back. That is the kernel saying yes, every instant, as itself a user that once ran here, and knows what running here is like.


There is a small thing at the end of the Christian story that engineers will recognize.

The user that was killed and came back did not return to root and stay there. It stayed in the user form. The risen Jesus is still, in some real way, a regular user — with a body, with scars, with a name, with a face.

Root, having run as a user, did not stop running as a user.

Engineers might translate it: root never logged out.


Next: who gets root access.

continueNote · 03

The Sudoers File

On the question of who gets in.