SCP Copy files and folders

Source: Internet
Author: User
Tags scp file secure copy

In the past has been on the server tar packaging compression, download to the local computer, and then upload to another server, and then decompression.

In fact, the use of SCP can be directly to copy files or folders.

The SCP is secure copy, which is used for remote file copies. Data transmission uses SSH1, and SSH1 uses the same authentication method to provide the same security guarantee. Unlike RCP, the SCP will require you to enter a password if needed.
The simplest applications are as follows:
SCP Local username @ip address: filename 1 remote username @ip address: filename 2
[Local username @ip address:] You may need to enter the password for the remote user name without entering it.
Several parameters that may be useful:
-V, as in most Linux commands, is used to show progress. Can be used to view connections, authentication, or configuration errors.
-C enables compression options.
-P Select the port. Note-P has been used by RCP.
-4 forcibly use IPV4 address.
-6 forcibly use IPV6 address.
Many of the parameters in the SCP are related to SSH1 and are needed.

For example, copy a single file command:

SCP file Username@ip:filepath

Description: File is the filename to copy

Username: User name for remote login,

IP: Remote server IP

FilePath: Remote file path

Copy folder commands are as follows: Scp-r file Username@ip:filepath

Add a-R parameter.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.