使用PSCP传输文件方法
版权声明:原创作品,允许转载,转载时请务必以超链接形式标明文章 原始出处 、作者信息和本声明。否则将追究法律责任。http://netocool.blog.51cto.com/61250/82396 |
PSCP是putty 安全复制客户端,使用SSH,可以很方便地在windows 系统传输文件到Linux 系统中。
只需输入命令就可以将windows下的文件传输到Linux系统的磁盘中:
C:\>pscp.exe
PuTTY Secure Copy client Release 0.60 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:\>pscp.exe d:\BAB115Linux.zip root@10.1.1.15:/root //将本地d:\BAB115Linux.zip 文件传输到10.1.1.15主机的/root目录下
The server's host key is not cached in the registry. You
have no guarantee that the server is the computer you think it is. The server's rsa2 key fingerprint is: ssh-rsa 1024 26:e3:66:c6:b1:e0:60:50:9a:5a:1a:e1:dd:fd:d2:53 If you trust this host, enter "y" to add the key to PuTTY's cache and carry on connecting. If you want to carry on connecting just once, without adding the key to the cache, enter "n". If you do not trust this host, press Return to abandon the connection. Store key in cache? (y/n) y root@10.1.1.15's password: BAB115Linux.zip | 576045 kB | 2493.7 kB/s | ETA: 00:00:00 | 100% 第一次在本地使用会提示是否保存SSH Key,选择Y保存即可。
C:\>pscp.exe -P 2202 BAB115Linux.zip root@10.1.1.15:/root
-P参数指定SSH使用的端口。
本文出自 “网络记忆棒” 博客,请务必保留此出处http://netocool.blog.51cto.com/61250/82396 本文出自 51CTO.COM技术博客 |


netocool
博客统计信息
热门文章
最新评论
友情链接