In this lesson, we will be creating a new user account.
This is done because using the root user account is quite dangerous for day-to-day administration of the server.
The root user has the ability to delete critical system files.
When using command lines, it's easy to mistype a command and accidentally delete or edit an important file. This will cause your server to stop running correctly and potentially cost you a lot of time and resource to repair the problem.
By creating a non-root user, we can avoid costly mistakes, because by default, non-root users do not have the same administrative privileges as root users.
Another advantage is that we can temporarily elevate non-root user privileges by typing "sudo" in front of our commands.
To add a new user account named "bob", type the following:
Next, we need to add the new user to the sudo group so we can elevate the user's privileges when needed.
adduser bob sudo
Now that we have our new user created, we no longer need to use the root account.
Type "exit" to logout as root.
We will now log back in as user bob.