From FreeBSDwiki
Jump to: navigation, search

scp -- secure copy. Essentially it's copying files from one host to another with ssh encryption. The format is:

scp user@host:/path/to/file user2@host2:/path/to/file2

Here user@host is copying file to host2 and naming it file2. You will need to use the -r flag if you want to scp recursively, for example if you wanted to copy a user's home directory:

scp -r /home/username

... which would copy "username"'s home directory (and all the files and directories it contains) from the local machine to the machine at "".

For information on encryption and authentication, tunneling over ssh, or other details, see the man page.

Personal tools