Linux SCP File Replication

Source: Internet
Author: User
Tags file copy scp file scp command secure copy

SCP is the abbreviation for secure copy, and SCP is a secure remote file Copy command under the Linux system based on SSH login. Use of the  1.SCP command:  SCP copies files between different hosts on the network, transmits data using SSH security protocols, and has the same authentication mechanism as SSH to secure remote copy files.   2.SCP Command Basic format:  SCP [ -1246BCPQRV] [-C cipher] [-f ssh_config] [-i-identity_file] [-L-limit] [-O ssh_option] [-P Port] [-S program] [[[Email protected]]host1:]file1 [...] [[[EMAIL PROTECTED]]HOST2:]FILE2  3.SCP Command parameter Description:  -1 Force SCP Command using Protocol ssh1 -2 Force SCP command using protocol SSH2 The  -4 Force SCP command only uses the IPV4 addressing  -6 to force the SCP command to use the batch mode only with IPV6 addressing  -b (no transmission password or phrase is queried during the transfer)  -c allow compression. (Pass the-c flag to SSH to turn on compression)  -p preserves the original file's modification time, access time, and access rights.  -Q does not display the transfer progress bar.  -r recursively replicates the entire directory.  -v shows the output in verbose mode. SCP and SSH (1) will display debugging information for the entire process. This information is used to debug connections, authentication, and configuration issues.  -C cipher encrypts the data in cipher, and this option is passed directly to SSH.  -f ssh_config Specifies an alternative SSH configuration file that is passed directly to SSH.  -i Identity_file reads the key file that is used when transferring from the specified file, this parameter is passed directly to SSH.  -l limit limits the bandwidth that the user can use, in kbit/s units.  -o ssh_option If you are accustomed to using the parameter passing method in Ssh_config (5),  -p port   Note is uppercase P, port is the port number specified for data transfer  -s program Specifies the program that is used to encrypt the transfer. This program must be able toEnough to understand the options for SSH (1).   4. Using examples (copying files under directories and directories)   (1) remote server, Local: Scp-r local-1-1-4-1/* 10.2.71.11:/data/www.test.com/  (2) Remote server-Local: scp-r  10.2.71.11:/data/www.test.com/*   Local-1-1-4-2

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.