图-ProFTPD
设定以 xinetd 来启动 proftpd :
事實上,目前大部分的 FTP daemon 多是以 super daemon 來啟動的!所以這裡我們也直接以 xinetd 來設定 proftpd 吧!畢竟多了一層管理,會更安全的啊! ^_^!設定的方法也真是很簡單~只要編輯 xinetd 底下的 proftpd 以及 proftpd.conf 檔案裡面的一些內容即可! [root@test root]# vi /etc/xinetd.d/proftpd
service ftp
{
disable = no
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/local/proftpd/sbin/proftpd
server_args = -c /usr/local/proftpd/etc/proftpd.conf
log_on_success += DURATION USERID
log_on_failure += USERID
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
# 上面的重點在於兩行粗體字的地方!尤其是 server =.. 那一行!
# 由於我們是使用 Tarball 安裝的,自然就以我們的檔案放置目錄為主,
# 如果您使用 RPM 安裝,這裡就不太相同囉!
# 另外,那個 server_args 後面接的則是設定檔的檔名咯!
[root@test root]# vi /usr/local/proftpd/etc/proftpd.conf
# 找到底下這個設定值:
ServerType standalone
Group nogroup
# 因為我們的系統預設並沒有 nogroup 這個群組,所以必須要將他改成
# 系統裡面有的群組才行吶!而伺服器啟動的方式有 super daemon 與
# stand alone ,所以:
ServerType inetd
Group nobody
[root@test root]# /etc/rc.d/init.d/xinetd restart
[root@test root]# netstat -tlnp
tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN 8483/xinetd
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
# 呵呵! 21 這個埠口出現了!理論上沒有問題,不過還是需要分析一下
# /var/log/messages 這個檔案的內容才行喔!
一般來說,我們還是比較建議使用 xinetd 的方式來啟動服務的,尤其是 FTP 之類的伺服器架設。在這個案例當中,我們就使用了 xinetd 來啟動,不過, proftpd 的設定檔 proftpd.conf 裡面就必須要規定好 ServerType 這個設定值,有兩個選擇:
standalone:表示獨立啟動的意思;
inetd:表示使用 super daemon ,不論是 inetd 或者是 xinetd 均使用這個設定值。
所以囉,這裡需要修訂好才行!然後就可以正確的來啟動囉!很簡單吧! ^_^!
通过鸟哥的文章,我们可以清楚的看出用设定 xinetd 这种方式來启动 proftpd 非常简单,希望大家都能学会他!
【编辑推荐】
- proftpd 的结构详解
- Proftpd建立特殊交流账号
- proftpd.conf 针对匿名者的设置
- proftpd.conf 针对实体用户的设置
- proftpd.conf 的设定方式
- 最简单的 Proftpd.conf 设定档
- Linux下安装配置与管理proftpd
- ProFtpd入门指南