码迷,mamicode.com
首页 > 其他好文 > 详细

sftp使用方法

时间:2017-07-09 21:57:14      阅读:533      评论:0      收藏:0      [点我收藏+]

标签:sftp   linux   redhat   



SecureCRT 按下 ALT+P 或者“文件——连接SFTP会话”,打开会话窗口。


1、help命令:显示帮助


2、pwd:查询linux主机所在目录


3、lpwd:查询本地目录


4、ls:查询linux主机所在目录文件


5、lls:查询本地目录文件


6、cd:更改linux目录


7、lcd:更改本地目录


8、get:从linux下载文件到本地


9、put:从本地上传


10、exit


***********************************************************************************

sftp> help

Available commands:

ascii                          Set transfer mode to ASCII

binary                         Set transfer mode to binary

cd path                        Change remote directory to ‘path‘

lcd path                       Change local directory to ‘path‘

detail remote-path             Display system information about remote

                                 file or folder

ldetail local-path             Display system information about local

                                 file or folder

chgrp group path               Change group of file ‘path‘ to ‘group‘

chmod mode path                Change permissions of file ‘path‘ to ‘mode‘

chown owner path               Change owner of file ‘path‘ to ‘owner‘

exit                           Quit sftp

help                           Display this help text

include filename               Include commands from ‘filename‘

                                 Alternate: < filename

get [-r][-a | -b] remote-path  Download file

                                 -r downloads directory recursively

                                 force ascii (-a) or binary (-b) mode

ln [-s] existingpath linkpath  Hardlink / symlink remote file

ls [options] [path]            Display remote directory listing

lls [options] [path]           Display local directory listing

mkdir path                     Create remote directory

lmkdir path                    Create local directory

mv oldpath newpath             Move remote file

lmv oldpath newpath            Move local file

open [user@]host[:port]        Connect to remote host

put [-r][-a | -b] local-path   Upload file

                                 -r uploads directory recursively

                                 force ascii (-a) or binary (-b) mode

pwd                            Display remote working directory

lpwd                           Print local working directory

quit                           Quit sftp

rename oldname newname         Rename remote file

lrename oldname newname        Rename local file

rmdir path                     Remove remote directory

lrmdir path                    Remove local directory

rm path                        Delete remote file

lrm path                       Delete local file

su username                    Substitutes the current user

                                 This is only supported with VShell for 

                                 Windows 3.5 or later.

type [transfer-mode]           Display or set file transfer mode

view remote-path               Download and open file

version                        Display protocol version

sftp> 

***********************************************************************************

本文出自 “风之谷” 博客,请务必保留此出处http://chenchunjia.blog.51cto.com/1878790/1945698

sftp使用方法

标签:sftp   linux   redhat   

原文地址:http://chenchunjia.blog.51cto.com/1878790/1945698

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!