Guide – How To Start – FTP Server on Ubuntu 21.04 Minimal

Connection to FTP Server on Ubuntu 21.04 Minimal

  1. For the VM to work, you need to open port 21(TCP), 22(TCP), 50000-51000(TCP) in the network properties in Azure Firefall.
  2. Install PuTTY. You can download PuTTY from the link – https://putty.org.ru/download.html Launch PuTTY.
  1.  In the “Host Name” field, enter the IP of the virtual machine and click “Open”.
  1. In the window that appears, click Accept.
  1. Enter the username and password that was used to create the virtual machine.

(If you enter a password, it will not be displayed.)

  1. To create a new user use the command 

sudo useradd -m  user name

Where username is the name that the user comes up with

  1. To create a password, use the command

sudo passwd user name

Where username this is the ftp user created in the previous step

Important: When entering a password for security purposes, it will not be displayed, also password has to be a maximum of 8 characters. If you enter a password with more than 8 characters, it will be shortened. While entering a password in the FTP client, only the first 8 characters will be taken.

  1. Then you need to enter the command in the console that opens the configuration file:

           sudo nano /etc/vsftpd/vsftpd.conf

           And add the following information there

pasv_enable=YES

pasv_address=xxx.xxx.xxx.xxx

pasv_min_port=YYYYY

pasv_max_port=YYYYY

Where xxx.xxx.xxx.xxx The public ip address of this vm

And YYYYY – Unprivileged ports (Must be allowed in VM security group).

  1. In order to save the information, press Ctrl + X, then Enter

Connection with Filezilla client 

  1.  Now, for further connection, you need to install  “FileZilla Client”

You can download it from the link: https://filezilla-project.org/download.php?platform=win64

  1. In the “Host” field, enter the IP of your VM

In the “Username” and “Password” fields, enter the data that you entered when creating a new user (see step 7)

In the “Port” field, enter 22

And click “Quickonnect”

  1. The examples of the basic ftp user management commands that can be entered after connecting in the PuTTY client: 

The changing of the password for an existing user:

sudo passwd username

The deletion of user:

sudo userdel username

The blocking of user account: (works only for password login)

sudo usermod -L username

The unblocking of user account:(works only for password login)

sudo usermod -U username

Website Built with WordPress.com.

Up ↑

%d bloggers like this: