I bought a raspberry pi so that I can learn Linux, but I'm confused with the users.
pi the main user or admin? Or is
root the same user?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.Sign up to join this community
They are two different individuals.
root is a common Linux and Unix super-privileged person, who can do anything on the system.
pi is a default account created by Raspbian installer. Such an account, though it may be named differently and might behave differently on differents OSs, is usually created by all Linux installers. It will usually be somehow able to gain root powers. The logic here is that as few things as possible should be done as root, as little time as possible spent as root, and as few root sessions should be open. Thus you can use either
sudo to elevate your
pi user for certain tasks. See
man su and
man sudo for a good start.
In Linux, you have 2 types of users - the root user (administrative user) and all the other users on the system. (slight over simplification)
On a Rasbian system, the pi user is Just A User.
However, that user is a member of a group that allows them to use the
sudo utility to run commands as if they were the root user.