How to add a new user to your vps

Step 1 – Login to your vps with your username
username@desktopname:~$ ssh username@yourvpsip

Enter your password.

Step 2 – Add a new user to the system.

The system automatically chooses for the directory /home.

Now use the adduser command to create a new user for your VPS.

username@yourvps:~$ sudo adduser username
Step 3 – Logout of the system.
username@yourvps:~$ exit
Step 4 – Login as the newly created user

Now you log in again , but as the newly created user.

username@desktopname:~$ ssh newusername@yourvpsip
Step 5 – Create a directory public_html

Open Midnight commander and create a directory public_html.

This is where you can put for example your wordpress site.

Step 6 – Give your new user administrator rights

Now you have to give your new user administrator rights.

This you have to do under your username, so first exit

newusername@yourvps:~$ exit

Now log back in with your main username.

username@desktopname:~$ ssh username@yourvpsip

and then use the visudo command

username@yourvps:~$ sudo visudo
Enter your password
 [sudo] password for username:
username@yourvps:~$ exit

Now login with the username you just created.

username@desktopname:~$ ssh newusername@yourvpsip

Now test out if the sudo command is working under your new username.

newusername@yourvps:~$ sudo su
[sudo] password for newusername: