- 论坛徽章:
- 0
|
在FreeBSD下安装PURE-FTPD [原创]
作者: wandering E-mail: wandering_997@yahoo.com
原链接: http://wandering997.yculblog.com/post.1063821.html
http://www.pureftpd.org
1. 安装pure-ftpd
---------------------
shell> tar zxvf pure-ftpd-1.0.20.tar.gz
shell> cd zxvf pure-ftpd-1.0.20
shell> ./configure --prefix=/usr/local/pureftpd --with-everything --with-language=simplified-chinese
shell> make
shell> make install
shell> mkdir /usr/local/pureftpd/etc
shell> cp ./configuration-file/pure-ftpd.conf /usr/local/pureftpd/etc
shell> cp ./configuration-file/pure-config.pl /usr/local/pureftpd/sbin
shell> chmod u+x /usr/local/pureftpd/sbin/pure-config.pl
2. 建立用户及相关文件
----------------------------
shell> cd /usr/local/pureftpd/
shell> pw group add -n ftpgroup -g 2000
shell> pw user add -n ftp -g ftpgroup -s /usr/sbin/nologin
shell> ./bin/pure-pw useradd jack -u 2001 -g ftpgroup -d /data1/it
Password: <new password>
Enter it again: <new password>
shell> ./bin/pure-pw mkdb
如果./bin/pure-pw mkdb出错则使用下面语句:
shell> ./bin/pure-pw mkdb /usr/local/pureftpd/etc/pureftpd.pdb -f /usr/local/pureftpd/etc/pureftpd.passwd
3. 配置pure-ftpd
--------------------
shell> vi /usr/local/pureftpd/etc/pure-ftpd.conf
ChrootEveryone no
TrustedGID 0
BrokenClientsCompatibility no
PureDB /usr/local/pureftpd/etc/pureftpd.pdb
AllowUserFXP yes
AllowAnonymousFXP yes
AnonymousCantUpload yes
IPV4Only yes
*这里我只列出了修改过的配置项, 其它的保持不变.*
4. 运行pure-ftpd
--------------------
shell> echo "/usr/local/pureftpd/sbin/pure-config.pl /usr/local/pureftpd/etc/pure-ftpd.conf" >> /etc/rc.local
shell> /usr/local/pureftpd/sbin/pure-config.pl /usr/local/pureftpd/etc/pure-ftpd.conf
OK, 可以使用了.
***注:
我在使用pure-ftpd中感觉它并不能建立一些虚拟目录,虽然它的configure选项中有类似的virtual host和alias,但我没有从网上找到任何可以借鉴的文档和帮助. 在尝试了一段时间后,我就放弃了. 决定不再使用pure-ftpd.
我要实现的目标是: 在一个用户的根目录下, 建立一个链接到其它硬盘目录的链接, 并可以对该链接读写. 这种形式类似于gene6中的目录设置.
Created by wandering 2006/01/09 15:44
[ 本帖最后由 wandering_997 于 2006-1-16 11:50 编辑 ] |
|