Recently I wanted to copy some files between two servers. Yes I haven’t done this before in a terminal session. Usually I utilize GUI powered tools to do the job via SFTP.
I decided to do this with SCP because it’s way faster than SFTP, http://www.kontrolit.net/glossary/ sais:
SFTP, Secure File Transfer Program similar to ftp, but performs all operations over an encrypted SSH transport, thus gaining the features of public key encryption and compression.
SCP, Secure Copy is a program to copy files between hosts on a network. It too uses SSH for authentication and data transfer, thus gaining the features of strong authentication and secure encrypted communications.
Some googleing brought me to this site: http://www.examplenow.com/scp/ Instead of bookmarking it I share the information with you.
These are some methods how you can copy files or whole directories: