Rotten mud: scp replication for CentOS command learning, rotten mud centos command scp

Source: Internet
Author: User
Tags scp command

Rotten mud: scp replication for CentOS command learning, rotten mud centos command scp

This article was sponsored by Xiuyi linfeng and first launched in the dark world.

Due to work requirements, you need to copy the files on server A to server B. I am too lazy to build FTP and Samba servers, so I plan to use the scp command, which is replicated through the ssh protocol.

You can view the scp command in the help document. As follows:

Scp -- help

Man scp

Scp [OPTIONS] file_source file_target

OPTIONS:

-V is the same as-v in most linux commands to display the progress. Can be used to view connections, authentication, or configuration errors

-C enable compression options

-P Select Port

-R copy directory

We will first test the local copy of files and directories to the remote server.

Copy an object as follows:

Scp./ilanni.tar.gz root@192.168.1.102:/ks

Scp-r./ilanni root@192.168.1.102:/ks

Scp root@192.168.1.102:/ks. cfg ./

Scp-r root@192.168.1.102:/ks/ilanni ./

We can see that the scp command has successfully copied all the ilanni directories in the/ks directory of the server 192.168.1.102 to the current directory.

The above describes how to use the scp command, which is commonly used.


The newly installed centOS 62 does not have the scp command. How can I install scp?

Yum install scp

After installing a Winscp, you can copy files from centos, but you cannot copy files from Win7 to Centos. What is the problem? Permission?

You do not have the write permission to copy data to the Centos directory.

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.