ftp 192.168.1.2html
提醒:分别输入用户名和密码进行认证;linux
特别注意:若是FTP 容许匿名用户,那么用户名要输入anonymous,密码任意。 不能直接敲回车。服务器
ftp > helpide
#查看指定命令的帮助信息
ftp > help put htm
1)get remote-file local-filerem
将一个文件从远程主机中下载到本地主机中get
例如:获取远程服务器上/usr/1.txt文件上传
ftp > get /usr/1.txt it
2) mgetclass
从远程主机下载一批文件至本地主机中
例如:获取远程服务器上/usr/下全部文件
ftp > cd /usr/
ftp > mget .
提醒:此时每下载一个文件都会提示,能够在mget命令执行前执行 prompt off 来关闭提示
ftp > !
1) put
put local-file remote-file
将本地一个文件上传至远端主机中
例如:将本地文件1.html上传到远程主机/usr/目录下,并重命名为2.html
ftp > put 1.html /usr/2.html
2) mput
将本地主机中一批文件上传至远程主机中
例如:将本地当前目录下全部html文件上传至远程服务器/usr/下
ftp > cd /usr/
ftp > mput *.html
ftp > pwd
ftp > lcd
ftp > mkdir remote-file
ftp > cd remote-file
指定的单个文件:
ftp > delete file1.txt
批量删除txt文件:
ftp > delete *.txt
ftp > bye