Gentoo LinuxFTPサーバー構成の下



Under Gentoo Linux Ftp Server Configuration



ホスト環境:Gentoo 11.2

カーネルバージョン:Linuxカーネル3.2.1



オリジナル作品、複製してください http://blog.csdn.net/yming0221/article/details/7360370




ここでは、FTPサーバーとしてproftpdを選択します

1、proftpdをインストールします

出現-avproftpd



2、proftpdを設定します

最初に/etc/proftpd/proftpd.conf.sampleをコピーします

cp /etc/proftpd/proftpd.conf.sample /etc/proftpd/proftpd.conf

適切な変更を加えてファイルを開きます

これが私のファイルです

ServerName 'yan's ftp server!' ServerType standalone DefaultServer on RequireValidShell off AuthPAM on AuthPAMConfig ftp RequireValidShell off # Listen on the standard FTP port 21. Port 21 # New directories and files should not be group or world writable. Umask 022 # To prevent DoS attacks set the maximum number of child processes # to 30. If you need to allow more than 30 concurrent connections # at once simply increase this value. MaxInstances 30 # The server will run under ftp/ftp. User ftp Group ftp # Every FTP sessions is 'jailed' into the user's home directory. DefaultRoot ~ # Generally files are overwritable. AllowOverwrite on # Disallow the use of the SITE CHMOD command. DenyAll SystemLog /var/log/proftpd.syslog TransferLog /var/log/proftpd.transferlog # A basic anonymous FTP account without an upload directory. User ftp Group ftp # Every FTP sessions is 'jailed' into the user's home directory. DefaultRoot ~ # Generally files are overwritable. AllowOverwrite on # Disallow the use of the SITE CHMOD command. DenyAll SystemLog /var/log/proftpd.syslog TransferLog /var/log/proftpd.transferlog # A basic anonymous FTP account without an upload directory. User ftp Group ftp # Clients can login with the username 'anonymous' and 'ftp'. UserAlias anonymous ftp # Limit the maximum number of parallel anonymous logins to 10. MaxClients 10 # Prohibit the WRITE command for the anonymous users. DenyAll Order deny,allow Allow from all
3、サービスを開始します

/ etc / proftpd / proftpd start

通常のFTPサーバーの場合、デフォルトの構成がより適切に構築されます。


ユーザーがftpログインにログオンすると、常に失敗し、ログを確認するという問題が発生しました

3月16日12:05:46yan-laptop proftpd [15868] yan-laptop:ProFTPD 1.3.3g(maint)(2012年3月16日金曜日10:36:06 CSTで構築)スタンドアロンモードスタートアップ
3月16日12:05:46yan-laptop proftpd [15819] yan-laptop(yan-laptop [:: ffff:127.0.0.1]):FTPセッションが閉じられました。
3月16日12:05:52yan-laptop proftpd [15877] yan-laptop(yan-laptop [:: ffff:127.0.0.1]):FTPセッションが開かれました。
3月16日12:05:57yan-laptop proftpd [15877] yan-laptop(yan-laptop [:: ffff:127.0.0.1]):ftp:ディレクトリ/ home / ftp /にアクセスできません。
3月16日12:07:39yan-laptop proftpd [15877] yan-laptop(yan-laptop [:: ffff:127.0.0.1]):FTPセッションが閉じられました。
3月16日12:11:00yan-laptop proftpd [15868] yan-laptop:ProFTPDが強制終了されました(シグナル15)
3月16日12:11:00yan-laptop proftpd [15868] yan-laptop:ProFTPD1.3.3gスタンドアロンモードシャットダウン

解決:

aclUSEマークを削除し、proftpdインストールを再コンパイルします

USE = '-acl'emerge proftpd

サービスを再起動すると問題が解決しました。