读书人

winscp在windows上批处理通过SSH端口下

发布时间: 2012-07-15 20:20:06 作者: rapoo

winscp在windows下批处理通过SSH端口上传文件
要执行的命令保存成文件willrun,内容:

option confirm off

open user:pwd@host1
put c:\test.txt /root/tmp
close

open user:pwd@host2
put c:\test.txt /root/tmp
close

open user:pwd@host3
synchronize remote c:\tmp /root/tmp -delete-----如果在目标机器存在,则加delete参数
close

exit





保存。





然后执行cmd

"c:\Program Files\WinSCP\WinSCP.exe" /console /script=c:\willrun.txt

读书人网 >windows

热点推荐