The document uses CVMs with CentOS 7.6 as an example to describe how to upload and download files via SCP.
You have purchased a Linux CVM.
Log in to the CVM console, navigate to the Instances page, and record the public IP of the CVM to which you want to upload files, as shown below:
Suppose that you want to upload the local file
scp [local file address] [CVM account]@[CVM instance public IP/domain name]:[CVM file location]
/home/lnmp0.4.tar.gzthe CVM (IP: 126.96.36.199) under the same directory, the command should be as follows:
scp /home/Inmp0.4.tar.gz email@example.com:/home/Inmp0.4.tar.gz
For example, you can run the following command to download the file
scp CVM account@CVM instance public IP/domain name: CVM file location local file address
/home/lnmp0.4.tar.gzfrom the CVM whose public IP is
188.8.131.52to the same local directory:
scp firstname.lastname@example.org:/home/Inmp0.4.tar.gz /home/Inmp0.4.tar.gz