Today topic in this article around the user management on Ubuntu such as add (create new user) & remove (delete) user both using Ubuntu terminal command line or graphical mode for discussion. The first option, How to add (Create) a User on Ubuntu and remove user on Ubuntu using Ubuntu command line.
1. Ubuntu command line to add and remove user:
A. Add (Create) a User on Ubuntu
Here are a few ideas that show how to create a new user from a terminal in Ubuntu, for example i want to add new user "mynewuser":
B. Add user to sudo group on Ubuntu
This will grant a newly created user (
C. Remove user
This Ubuntu command to delete user, in this case we want to delete existing user
2. Graphical mode to add and remove user on Ubuntu:
In this graphical mode mode to add and remove user on Ubuntu i used Ubuntu Gnome 16.04 to demonstrate. Go to "user setting" this could be found under Applications --> System Tools --> Settings --> Users or (in Gnome) click menu from your top right corner, under your user name click Account Settings
A. Adding User
Under "Users" menu, Simply click "unlock" and enter your password to make any User Management modification as root or Administrator.
- To add a new user click plus "+" sign. Next enter new user detail.
- Set Account type could be Standard or Administrator account for new added user.
- Then Fill Full Name, User Name and Password for new user.
by defaul Ubuntu will create "home directory" for the new user.
D. Delete User
To delete existing users, Simply select existing users you desire to delete then click minus "-" sign.
These how to create or add new user, remove or delete user add user to

1. Ubuntu command line to add and remove user:
A. Add (Create) a User on Ubuntu
Here are a few ideas that show how to create a new user from a terminal in Ubuntu, for example i want to add new user "mynewuser":
sudo adduser mynewuserIt will ask you for couple of questions like (password, fullname etc), you can input the data or skip by just hitting the enter key. Now we have a new user named
mynewuser
and by default above command will create users mynewuser
home directory as /home/
. next step how do we grant sudo privileges to this new user mynewuser
?.B. Add user to sudo group on Ubuntu
This will grant a newly created user (
mynewuser
) sudo
privileges (as sudoer) in Ubuntu using these commands:
sudo usermod -a -G sudo mynewuseror
sudo visudothen take a look at the following code:
# User privilege specification root ALL=(ALL:ALL) ALLAdd the following code right after (below) that line code to make grant root privileges to the user
mynewuser
:
mynewuser ALL=(ALL:ALL) ALLThis will grant privileges
mynewuser
. Now we have a user setup by the name of mynewuser which can use sudo to run commands as root.C. Remove user
This Ubuntu command to delete user, in this case we want to delete existing user
mynewuser
sudo userdel mynewuserabove command will remove user
mynewuser
, to remove all of the files for the user mynewuser
, use -r
option:
sudo userdel -r mynewuser
2. Graphical mode to add and remove user on Ubuntu:
In this graphical mode mode to add and remove user on Ubuntu i used Ubuntu Gnome 16.04 to demonstrate. Go to "user setting" this could be found under Applications --> System Tools --> Settings --> Users or (in Gnome) click menu from your top right corner, under your user name click Account Settings
A. Adding User
Under "Users" menu, Simply click "unlock" and enter your password to make any User Management modification as root or Administrator.
- To add a new user click plus "+" sign. Next enter new user detail.
- Set Account type could be Standard or Administrator account for new added user.
- Then Fill Full Name, User Name and Password for new user.
by defaul Ubuntu will create "home directory" for the new user.
D. Delete User
To delete existing users, Simply select existing users you desire to delete then click minus "-" sign.
These how to create or add new user, remove or delete user add user to
sudoers
or sudo
on Ubuntu using Ubuntu terminal command line. Manage user using Graphical mode (GUI) on Ubuntu Gnome 16.04.linuxlinx...