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

CentOS安装 pure-ftpd

时间:2015-04-25 00:09:49      阅读:183      评论:0      收藏:0      [点我收藏+]

标签:

yum -y install pam-devel

cd /usr/local
tar zxf pure-ftpd-1.0.36.tar.gz
cd pure-ftpd-1.0.36

./configure --prefix=/usr/local/pure-ftpd/ --with-puredb
make && make check && make install
mkdir -p /usr/local/pure-ftpd/etc/ touch /usr/local/pure-ftpd/etc/pureftpd.passwd /usr/local/pure-ftpd/bin/pure-pw mkdb /usr/local/pure-ftpd/etc/pureftpd.pdb cd /usr/local/pure-ftpd-1.0.36/configuration-file cp /usr/local/pure-ftpd-1.0.36/configuration-file/pure-ftpd.conf /usr/local/pure-ftpd-1.0.36/configuration-file/pure-ftpd.conf.backup vim /usr/local/pure-ftpd-1.0.36/configuration-file/pure-ftpd.conf 配置文件里pure-ftpd.conf 指定pdb位置 PureDB /usr/local/pure-ftpd/etc/pureftpd.pdb 修改端口 PassivePortRange 30000 30500 chmod 777 /usr/local/pure-ftpd-1.0.36/configuration-file/pure-config.pl /usr/local/pure-ftpd-1.0.36/configuration-file/pure-config.pl /usr/local/pure-ftpd-1.0.36/configuration-file/pure-ftpd.conf groupadd ftp_user useradd wfc_ftp gpasswd -a wfc_ftp ftp_user 使用 id wfc_ftp 查看组信息 大概会输出以下内容 uid=502(wfc_ftp) gid=503(wfc_ftp) 组=503(wfc_ftp),502(ftp_user) # 创建用户ftp根目录 mkdir -p /data/ftp_data/wfc chown wfc_ftp:ftp_user /data/ftp_data/wfc # 添加用户 # 语法 /usr/local/pure-ftpd/bin/pure-pw useradd $user -u $uid -g $gid -d $dir -m /usr/local/pure-ftpd/bin/pure-pw useradd wfc_ftp -u 502 -g 503 -d /data/ftp_data/wfc -m # 添加防火墙规则 vim /etc/sysconfig/iptables # 在适当位置添加 -A INPUT -p tcp --dport 21 -j ACCEPT -A INPUT -p tcp --dport 30000:30500 -j ACCEPT service iptables restart # pure-ftpd 命令帮助 # 查看已有用户 /usr/local/pure-ftpd/bin/pure-pw list # 删除用户 /usr/local/pure-ftpd/bin/pure-pw userdel $user -m # 修改密码 /usr/local/pure-ftpd/bin/pure-pw passwd $user -m

 

CentOS安装 pure-ftpd

标签:

原文地址:http://www.cnblogs.com/funsion/p/4455056.html

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