In linux, the scp command is generally used to transmit files through ssh. 1. download the file scpusername @ servername:/path/filename from the server such as scproot@192.168.0.101:/var/www/test.txt put/var/www/t on 192.168.0.101... in linux, the scp command is generally used to transmit files through ssh. 1. download the file scp username @ servername:/path/filename such as scp root@192.168.0.101 from the server: /var/www/test.txt download the/var/www/test.txt file on 192.168.0.101 to the current directory 2. Upload the local file to the server scp/path/filename username @ servername: /path, for example, scp/var/www/test. php root@192.168.0.101:/var/www/put the local/var/www/directory test. upload the php file to the/var/www/directory on the server 192.168.0.101. 3. download the entire scp-r username @ servername:/var/www/local_dir/from the server. for example: scp-r root@192.168.0.101:/va R/www/test/var/www/4. Upload the directory to the server scp-r local_dir username @ servername: remote_dir for example: scp-r test root@192.168.0.101: /var/www/upload the test directory under the current directory to the/var/www/directory on the server. note: The write permission must be enabled for the target server. Scp packages must be installed on both servers.
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