How to copy files using scp command to local and remote server

0
Nisha Verma 15 Rep. Avishek Kumar edited question

What is the correct syntax to copy files from local-to-local and local-to-remote server using scp command? Also, I want to know if transferring file this way is secure?

♥ Spread the love ♥
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
0
Avishek Kumar 449 Rep. Avishek Kumar edited answer

scp is a remote file copy program, which stands for secure copy. scp uses ssh (secure shell) to copy file using same credentials and security. It is the standard way of copying files from one host to another in a secure way.

Syntax

Example

Note: Here user dokws can write to /home/dokws/Desktop. You must copy the file to the location that is writable by the user you are doing scp, else scp won’t be able to write to the location and will fail. Following the best practice don’t use root account of another host while doing scp.

For more details on various scp options, you may like to go through its manual.

♥ Spread the love ♥
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
×

Login