Ubuntu 18.04 setup new root user

Requirements

  • Console access
  • root login or a user with sudo access

Creating your user

Run the following command into console. Replace {username} with your username. If you already created a user, skip to the next section.

adduser {username}

You will be prompted to enter your password twice, then some basic user information. The user information is not required and can be left blank.

Adding user to the Sudo group

Run the following command into console. Replace {username} with your username.

usermod -aG sudo {username}

There should be nothing output from this command. You can now login as {username} and run commands as root.

Leave a Reply

Your email address will not be published. Required fields are marked *