第一 下载pscp.exe文件
第二 将pscp.exe的路径加入到系统环境变量Path中,这样我们就可以在Windows的命令行下使用pscp命令了。
F:\AppServ\Apache2.2\bin;F:\AppServ\php5;F:\AppServ\MySQL\bin;C:\Program Files (x86)\SSH Communications Security\SSH Secure Shell;C:\Users\Default\Pscp
第三 此时使用pscp命令既可以拷贝文件到远端的Linux系统中,或者从远端的Linux系统中拷贝文件到当前路径,该命令使用方法类似于Linux下的scp命令。
Microsoft Windows [版本 6.3.9600]
(c) 2013 Microsoft Corporation。保留所有权利。
C:\Users\lenovo>pscp
PuTTY Secure Copy client
Release 0.62
Usage: pscp [options] [user@]host:source target
pscp [options] source [source...] [user@]host:target
pscp [options] -ls [user@]host:filespec
Options:
-V print version information and exit
-pgpfp print PGP key fingerprints and exit
-p preserve file attributes
-q quiet, don't show statistics
-r copy directories recursively
-v show verbose messages
-load sessname Load settings from saved session
-P port connect to specified port
-l user connect with specified username
-pw passw login with specified password
-1 -2 force use of particular SSH protocol version
-4 -6 force use of IPv4 or IPv6
-C enable compression
-i key private key file for authentication
-noagent disable use of Pageant
-agent enable use of Pageant
-batch disable all interactive prompts
-unsafe allow server-side wildcards (DANGEROUS)
-sftp force use of SFTP protocol
-scp force use of SCP protocol
C:\Users\lenovo>pscp D:\123.txt root@192.168.3.1*1:/root/data
root@192.168.3.1*1's password:
C:\Users\lenovo>