DEV Community

Seb
Seb

Posted on • Updated on

File Transfer Commands in Linux

Here is an overview of commands you can use when handling file transfers in Linux

Due to the fact that is a beginners article, it will just be the most basic information.

I do plan to release future articles adding more details about these commands and how to actually use them.

Since I already made this article into a tweet, you can also check that out here.

ftp

'ftp' stands for 'file transfer protocol'. You can use this, but this is an insecure way of transferring files to and from a host because when you enter your username and password it will travel over the network in plain text

sftp

'sftp' stands for 'secure file transfer protocol'. This is the secure way of transferring. Using stfp will provide a higher level of transfer protection

scp

'scp' copies files to and from a host in a secure way.

This command is considered outdated by some people and companies. It works, but use at your own discretion!

rsync

'rsync' is used to synchronize files and directories between two machines over a remote shell.

annddd

ssh

'ssh' is used to securely log onto a remote host. You can 'ssh' into a remote system using SSH keys or password authentication.

This one technically is not a file transfer command but I believe it is important when it comes to it.

Wooo!!!

annddd that is all! I do plan to post more longer tutorials and informational articles in the future!

If you enjoyed this article, feel free to give me a follow! :)

Latest comments (3)

Collapse
 
m4r4v profile image
m4r4v

FTP is not entirely unsecure. If you choose to authenticate with a certificate, it will not be so unsecure anymore.

SFTP uses the ssh protocol

Rsync use ssh to sync files between two different machines, local and remote

Collapse
 
guss77 profile image
Oded Arbel • Edited

Eh. Nitpicking:

  • sftp is using the SSH protocol, you should have mentioned that.
  • scp is an old way to use the SSH protocol to transfer files and is obsolete and should not be used. Also, I didn't understand the comment about "used after you ssh" - you most definitely can use scp from your local machine to a remote one.
  • ssh is not actually a file transfer command, though it can be used with pipes so we often pipe data from a file on one side to pipe it out to a file on the outer side - but more context would have been appreciated. If you mention SSH then nc would probably have been worth mentioning as well.
  • if you've mentioned ftp, then other "clients" are probably worth mentioning, such a curl and wget - both do anything that ftp does and more.

Lastly, there's a bunch of new stuff that is useful: croc and magic wormhole might be worth mentioning.

Collapse
 
linuxseb profile image
Seb

Thumbs up Emoji

Can't wait for your content:)