Use scp to back up files on a remote server to a local device

Source: Internet
Author: User
Tags scp command

When images on the remote server need to be backed up, we can use the scp command of Linux to remotely copy images to the local device.

Let's briefly introduce the usage of scp:

Syntax format: scp [OPTIONS] file_source file_target

OPTIONS:

-V is the same as-v in most linux commands. It is used to display the progress. It can be used to view the connection, authentication, or configuration error.

-C enable compression options

-P: Select the port. Note that-p has been used by rcp.

-R recursion of all objects below

Example:

Copy the local/home/test. log file to the remote/home/root directory
Scp/home/test. log root@121.199.25.174:/home/root (this will let the input remote server password, start copying ...)
 
Copy from the remote/home/root/test. log directory to the local/home directory
Scp root@121.199.25.174:/home/root/test. log/home (this will let the input remote server password, start copying ...)

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.