阿里云上安装vsftp笔记,阿里云vsftp笔记
阿里云上安装vsftp笔记,阿里云vsftp笔记
安装 ftp
1 ssh登录服务器
首先检查有没有安装运行 ps -ef |grep vsftpd
2 yum安装vsftpd
yum安装 yum istall vsftpd -y
3 修改配置 、增加开机启动
vi /etc/vsftpd/vsftpd.conf
anonymous_enable=YES改成NO
保存退出
查看vsftpd又没有被设置为开机自启动
chkconfig --list
加入开机启动
chkconfig --level 35 vsftpd on
4 增加FTP用户、并设置密码
cd alidata
mkdir www
useradd ftpadmin -s /sbin/nologin -d /alidata/www
passwd ftpadmin
chown ftpadmin www 或者 chmod 777 www
5 启动ftp
service vsftpd start
来自视频:http://help.aliyun.com/view/11108189_13495137.html?spm=5176.7224473.1997282753.6.6VPxgo
发现这样配置后:可以再windows系统的dos下使用ftp命令登录。 但是不能使用ftp工具列出文件列表。这是怎么回事?
解决ftp无法list目录,配置主动、被动模式
FTP as protocol is a bit of an odd duck. It uses two TCP connections, rather than just the one most protocols use. You have port 21, the command and login connection, and a second connection, the data connection. With passive FTP the second connection is to a randomly assigned available TCP port above 1024. You problems seem to indicate you don't have that second port open in your firewall. There's multiple ways to deal with that: Fixed the PASV port(-range) One solution is to configure VSFTPD to use a small range of ports, or just a single port and create a firewall rule to open those ports:
# /etc/vsftpd/vsftpd.conf # reserve TCP ports 2121-2142 for passive FTP pasv_min_port=2121 pasv_max_port=2142 And then open the port range in your firewall. (The multiport module allows for a port range rather than 20 lines each opening a single port): # iptables -I INPUT -p tcp -m state --state NEW -m tcp -m multiport --dports 2121:2142 -j ACCEPT # service iptables save # service iptables restart 摘自:http://serverfault.com/questions/555541/failed-to-retrieve-directory-listing-in-filezilla-connecting-to-vsftpd 关于 ftp主动模式和被动模式 可以参考:http://jackiechen.blog.51cto.com/196075/193883/ 案例:ftp被动模式端口相同导致无法登录:http://u2l.info/3n6kav |
6 /etc/vsftpd/vsftpd.conf详解
可以参考 http://blog.chinaunix.net/uid-24625974-id-2845256.html(有案例)
先 yum -y install yum-fastestmirror
然后在yum -y install vsftpd
你好.我来解答下你的问题
WIN系统下安装FTP最常用的是SERV-U服务端.你只需要下载按提示安装.配置即可搭建FTP.如果是ASP或者PHP的网站.可以通过IIS来发布.上传数据到FTP以后需要在IIS中配置网站.而想要让别人通过域名来访问你的网站.是需要你注册一个域名并解析和绑定.不是服务器自动生成的.通常一个域名只需要几十元.在域名管理后台解析指向你的服务器IP.然后在服务器IIS中添加主机头.如果是正规的IDC公司.以上这些内容都可以帮你完成的.
海腾数据杨闯为你解答.若有服务器相关问题需要帮忙的可以找我
评论暂时关闭