2

I have a digital ocean droplet. I am able to connect to it using SSH and see the file list in the terminal. There is a folder in the droplet which I would like to download to my PC. How can I do that using a Ubuntu Linux terminal? Or should I use some FTP software to do that in Linux?

zorbamj
  • 33
  • I don't know your specifics, but you're using secure-shell (ssh) to shell into the box, I'd use secure-copy (scp) to copy files using the same mechanism. – guiverc Jun 29 '19 at 12:12
  • Thank You. I searched for scp and it worked. Sorry if it was a dumb question, I am very new to linux – zorbamj Jun 29 '19 at 12:23
  • Not a problem, if you man ssh to view the reference manual page for ssh, you'll note a SEE ALSO section which includes other commands that may be useful, where scp is first, sftp second etc... There are loads of tools as get the hang of it (and when you forget commands, apropos or use autocomplete.. – guiverc Jun 29 '19 at 12:26
  • Actually, ssh provides sftp, and you can use a file browser to connect and copy files. https://askubuntu.com/questions/1126120/share-between-ubuntu-18-10-machines-without-samba/1126122#1126122 – mikewhatever Jun 29 '19 at 12:27

1 Answers1

2

By default the open-sshserver comes with enabled SFTP feature, so you can use it as it is described here: Filezilla or WinSCP alternative for Ubuntu.

For a single file or directory (also with recursion) either scp or rsync are appropriate. For better performance I would use rsync in a way as this:

rsync -av user@host:/remote/path/to/<file or directory> /local/path/<to be placed>

In the topic mentioned above, I'm describing also how to setup and use the ~/.ssh/config file. Because you are new to linux, if you are not familiar with that, IMO, this part will be useful for you.

pizzaisdavid
  • 103
  • 3
pa4080
  • 29,831