PSCP using a detailed win and Linux file Transfer tool

Source: Internet
Author: User
Tags file copy pscp

PSCP How to use:
The PSCP is a remote file transfer tool with the Putty installation package, which is a very common tool for file transfer between Windows and Linux systems, and is similar to the SCP in Linux, where you'll find a detailed usage approach.

pscp:http://download.csdn.net/detail/doiido/8442599
Version: Release 0.60

Grammar:
PSCP [Options] [[Email Protected]]host:source target
PSCP [options] source [source ...] [[Email Protected]]host
PSCP [Options]-ls [email protected]:filespec

Common options:
-L: Connect with the specified user
-P: Preserve source file properties when transferring
-P: Specify the port to connect to (default 22)
-PW: Specifies the password for the logged-on user (shown)
-Q: No prompt message is displayed during transmission
-r: Recursively copy entire Directory
-V: Display a prompt message when transmitting
-V: Print version information and exit

Other options:
-1/-2: Forcing the version of the specified SSH to be used
-4/-6: Forcing the use of IPv4 or IPV6
-agent: Using Pageant
-noagent: Do not use pageant
-batch: Disable all interactive hints
-C: Using compression
-I: Specify the private key file required for authentication
-load: Load saved session settings
-PGPFP: Print PGP key fingerprint and exit
-SCP: Mandatory use of SCP protocol
-SFTP: Forcing the SFTP protocol to be used
-unsafe: Allow server-side wildcard characters (dangerous)


How to use:

Start → run →cmd, in the DOS command environment, switch to the directory where Pscp.exe is located, and then call

It is recommended that you put Pscp.exe in C:\WINDOWS\system32, and then you can call anywhere



Note: PSCP will use the Windows login username, so you will need to specify the Linux user name.


Common scenarios
Local files are copied to the remote server
Local directories and files in the directory are copied to the remote server
Copy files from the remote server to the local
Directories in the remote server and files in the directory are copied to the local


Instance:
1. local file copy to remote server
Format: PSCP local_file [Email protected]:/remote_dir

Use the Dodo user to upload the Doiido.txt file under the D drive to the/doiido/directory of the Linux host with IP address 192.168.100.250
Pscp-l Dodo D:\doiido.txt 192.168.100.250:/doiido
PSCP D:\doiido.txt [Email Protected]:/doiido

Note:<1> above two statements function the same
<2> "-L Dodo" before file



2, local directories and files in the directory are copied to the remote server

Format: PSCP local_dir [Email protected]:/remote_dir


use Dodo user to upload the Hello directory under D disk to the 192.168.100.250 directory of the Linux host with the IP address/doiido/
pscp-r D:\hello [email protected]:/doiido


3, the files on the remote server are copied to the local
format: PSCP [ Email protected]:/file \local_dir 

Save the file Test.sql in the/doiido directory in the Linux host to the local
pscp [email protected]:/doiido/test.sql D:\hello\test.sql


4, The directory in the remote server and the files in the directory are copied to the local
format: pscp-r [email protected]:/remote_dir \local_dir

Use Dodo user to connect the Linux host/ The Doiido directory and the files in the directory are saved to the local
pscp-r [Email protected]:/doiido/hello1 D:\hello2

This will save the Hello1 directory in the Hello2 directory
 

5, use
to transfer all content in the local fileupload directory on a remote Linux server/ Doiido directory, the following
(1) to copy the Pscp.exe to FileUpload's sibling directory
(2) Create a new Doiido file, and then end with a bat, the Doiido.bat
(3) file content is as follows
@ECHO now begin to upload file
@pscp-R FileUpload [Email protected]:/doiido
@PAUSE

(4) Put the files you want to upload into the FileUpload directory, double-click Doiido.bat to


PSCP using a detailed win and Linux file Transfer tool

Related Article

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.