Here is one small useful tutorial about how to add user in Ubuntu via command line or GUI. Default command in Linux is useradd, but it is quite complicated and not easy to use. But Debian and any other derivatives such as Ubuntu and Linux Mint has a more friendly and useful command which is called adduser. Here is what man pages says about both commands. First is useradd is a low level utility for adding users. On Debian, administrators should usually use adduser(8) instead. Second is adduser and addgroup add users and groups to the system according to command line options and configuration information in /etc/adduser.conf. They are friendlier front ends to the low level tools like useradd, groupadd and usermod programs, by default choosing Debian policy conformant UID and GID values, creating a home directory with skeletal configuration, running a custom script, and other features.
Basically command adduser is a interactive Perl scripts that ask you a couple of question and then do the right job. And of course Ubuntu provides nice GIU to manage users – how to add them, delete, block and change their passwords.
How to add user via command line
Let’s look into command than you need to execute in order to create a new user account. Here we will discuss different parameters that you need to pass to adduser command. Basically what you need to do is just to provide a login name for a new user. Then adduser command will ask you a couple of questions and will create new account with a new password and proper home directory.
howopensource@esprimo:~$ sudo adduser test Adding user `test' ... Adding new group `test' (1004) ... Adding new user `test' (1004) with group `test' ... Creating home directory `/home/test' ... Copying files from `/etc/skel' ... Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully Changing the user information for test Enter the new value, or press ENTER for the default Full Name : Test Account Room Number : Work Phone : Home Phone : Other : Is the information correct? [Y/n] howopensource@esprimo:~$
If you want to add one existing user to an existing group then adduser command must be called with a two parameters. First one is a user and second one is a group to which to add specified user. Here is an example how to add newly created user to sudo group.
howopensource@esprimo:~$ sudo adduser test sudo Adding user `test' to group `sudo' ... Done. howopensource@esprimo:~$
There a couple of different options and parameters that you can specify to command adduser when you have to accomplish different tasks. But we are not going to discuss them here.
Ubuntu add user via control panel
Here is step by step explanation how to add user to Ubuntu via system settings. First click on Settings button on the upper right corner in the screen. Then you have to select System Settings… option from the drop down menu. Look into screen shot for more details.
Next step is to click on User Accounts icon in the bottom right corner of Settings window. On the screenshot bellow icon is highlighted.
Then a new dialog window called User Accounts is open. In this dialog you can manage users of the system. You can delete users by selecting user and pressing minus button in the bottom-left corner of window. Using plus button you can add new account. And there is Lock/Unlock button in upper-right corner. From this button you can lock or unlock user. When new user is created it is locked by default. You need to unlock it. During this process you need to set user password.
So to add new user account on Ubuntu just press plus button in bottom-left corner and follow the instructions in next dialog.
You need do specify only a few fields and to click add button. Next step is to set password for user and to activate user account. This can be done via Unlock button in the upper-right corner. When you press this button you will be asked to specify new user password. So you have to enter it.
And this is it. Hope this short tutorial will help you to manage you Ubuntu box in a better way.