
Here’s the syntax:Īdding new user `thegeek’ (1004) with group `thegeek’. The adduser command is even easier than the useradd command, because it prompts you for each piece of information. I find it slightly funny that there are two virtually identically named commands that do the same thing, but that’s linux for you. If you wanted to set default path options for all new users, you would do so by modifying the files in /etc/skel, which would then be used to create these files by the useradd command. You’ll notice that there are bash scripts in this directory.

First of all, create a user account in your system to use as sftp user.

A running Ubuntu 20.04 LTS system You must have sudo privileged account with shell access Step 1 Create User. If we take a look at the new home directory for the ls -la /home/testuserĭrwxr-xr-x 2 testuser testuser 4096 11:34. And restrict (chroot) the SFT user account to specific directory only. If you wanted to set default values for your users, you would do so by modifying or adding files in that directory. Steps to create a user account on Ubuntu Linux Open the terminal application Log in to remote box by running the ssh useryour-ubuntu-box-ip To add a new user in Ubuntu run sudo adduser userNameHere Enter password and other needed info to create a user account on Ubuntu server New username would be. This will create the user named testuser and give them their own home directory in /home/testuser. The files in the new home directory are copied from the /etc/skel folder, which contains default home directory files.
