■ ProFTPdとは・・・
FTPサーバの1つ。■設定
総合的に見るとユーザは多く、wu-ftpdと比べると認証速度が高いのと
設定項目がいろいろできるところがよくできています。バージョン1.2.10rc1から有名クライアントFFFTP標準のファイル一覧コマンド
"NLST" をサポートしなくなってしまいました。(基準に従うため)VineLinuxでは標準で入っているのでインストール項目は省きますが
apt-get install proftpd とうってもOKです。
設定ファイルは /etc/proftpd.conf ですので、こいつをいろいろと編集します。■バージョン1.2.10より新しい場合のTips
# vi /etc/proftpd.conf
# サーバ名
ServerName "FTP Server"# セキュリティのためデーモン名(ProFTPd)とバージョンを表示させない
# (以下のように違う文字列を表示させる)
ServerIdent on "FTP server ready."ServerType standalone
DefaultServer on
# ホームディレクトリより上位にアクセスさせない(chroot)
# しかし、「admin」だけは許可する、という設定。不要なら ~ のみ
DefaultRoot ~ !admin# サーバのドメイン
MasqueradeAddress ftp.homeserver.jp
DeferWelcome on# 逆引きを無効にしないとログイン時間が非常にかかってしまう
UseReverseDNS off IdentLookups off# 一定時間、何も転送しないと接続を切る。(以下は300秒=5分)
# (なくても動作に支障なし
TimeoutNoTransfer 300# umask(デフォルトパーミション)を指定する場合は、以下を例に追記
# (なくても動作に支障なし)
Umask 072# 最大接続ユーザ数 もし個人用途であれば「5」で十分です
MaxInstances 30# パスクラック対策として、パスワードの入力ミスは3回まで許す
MaxLoginAttempts 3↓Anonymouseを無効にするため削除または頭に#をつけコメントアウト
# A basic anonymous configuration, no upload directories. ## User ftp # Group ftp # We want clients to be able to login with "anonymous" as well as "ftp" # UserAlias anonymous ftp # Limit the maximum number of anonymous logins # MaxClients 10 #MaxClients 10 # do not require shells listed in /etc/shells (user ftp do not have shell...) # RequireValidShell no # We want 'welcome.msg' displayed at login, and '.message' displayed # in each newly chdired directory. # DisplayLogin welcome.msg # DisplayFirstChdir .message # Limit WRITE everywhere in the anonymous chroot # # DenyAll #
■ 適用&標準起動
設定が終わったので起動します(既に動いてるならrestart)
ProFTPdは標準設定だとマシン起動時にロードしてくれないので、ついでにONにします。あとはFTPクライアントから接続するだけです。
# /etc/rc.d/init.d/proftpd start
# cd /etc/rc.d/init.d
# chkconfig --lebel 2345 proftpd on
ちなみに20ポートと21ポートを使用しますので外部からもFTP接続するならば
ポートを開放しておいてください。