All for Joomla All for Webmasters

Linux SCP | What is Secure Copy

What is Secure Copy?

Secure Copy (scp) allows files to be copied to, from, or between different nodes. It uses ssh for data transfer and provides the same authentication and same level of security as ssh.


1. Copy the file “test.txt” from a remote host to the local host

$ scp /some/local/directory


2. Copy the file “test.txt” from the local host to a remote host

$ scp test.txt


3. Copy the directory “test” from the local host to a remote host’s directory “data”

$ scp -r test


4. Copy the file “test.txt” from remote host “” to remote host “”

$ scp \


5. Copying the files “test.txt” and “test1.txt” from the local host to your home directory on the remote host

$ scp test.txt test1.txt


6. Copy the file “test.txt” from the local host to a remote host using port 2264

$ scp -P 2264 test.txt


7. Copy multiple files from the remote host to your current directory on the local host

$ scp\{a,b,c\} .
$ scp\{test.txt,test1.txt\}


Secure Copy (scp) Performance

8. By default Secure Copy (scp) uses the Triple-DES cipher to encrypt the data being sent. Using the Blowfish cipher has been shown to increase speed. This can be done by using option -c blowfish in the command line.

$ scp -c blowfish some_file


9. It is often suggested that the -C option for compression should also be used to maximize the speed. The effect of compression, however, will only significantly maximize the speed if your connection is very slow. Otherwise it may just be adding extra burden to the processor. An example of using compression and blowfish:

$ scp -c blowfish -C local_file


Linux SCP | What is Secure Copy

log in

Become a part of our community!

reset password

Back to
log in
Choose A Format
Personality quiz
Trivia quiz