Use LFTP command line to transfer files from ftp server
Example source server
Host: host.example.com
username: exampleuser
password: examplepass
username: exampleuser
password: examplepass
Source folder: /public_html
To install lftp in ubuntu
#apt-get install lftp
Usage
To connect to the ftp server use
#lftp -u exampleuser,examplepass host.example.com -e ‘set ftp:ssl-allow no;’
Once your are connected you will see the below prompt
lftp exampleuser@host.example.com:~>
Use ls command to list files and directories
To copy the entire public_html directory use the following command
lftp exampleuser@host.example.com:~>mirror public_html /destination-path
Note: Lftp will not automatically create the destination-path. The destination path should exist