Linux4.0 FTP server relevant config
一.FTP 基本配置.
1. [root@michael ~]# rpm -qa | grep vsftpd vsftpd-2.0.1-5.EL4.5 [root@michael ~]# rpm -qa | grep vsftpd* vsftpd-2.0.1-5.EL4.5 2. [root@michael ~]# vi /etc/vsftpd/vsftpd.conf # Example config file /etc/vsftpd/vsftpd.conf # # The default compiled in settings are fairly paranoid. This sample file # loosens things up a bit, to make the ftp daemon more usable. # Please see vsftpd.conf.5 for all compiled in defaults. # # READ THIS: This example file is NOT an exhaustive list of vsftpd options. # Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd''s # capabilities. # # Allow anonymous FTP? (Beware - allowed by default if you comment this out). anonymous_enable=YES # # Uncomment this to allow local users to log in. local_enable=YES # # Uncomment this to enable any form of FTP write command. write_enable=YES # # Default umask for local users is 077. You may wish to change this to 022, # if your users expect that (022 is used by most other ftpd''s) local_umask=022 3. [root@michael ~]# grep -v "#" /etc/vsftpd/vsftpd.conf anonymous_enable=YES local_enable=YES write_enable=YES local_umask=022t dirmessage_enable=YES xferlog_enable=YES connect_from_port_20=YES xferlog_std_format=YES
pam_service_name=vsftpd userlist_enable=YES listen=YES tcp_wrappers=YES 4. [root@michael ~]# head -5 /etc/vsftpd.ftpusers <The file user deny login vsftpd server> # Users that are not allowed to login via ftp root bin daemon adm 5.[root@michael ~]# head /etc/vsftpd.user_list <The file user deny login vsftpd server too> # vsftpd userlist # If userlist_deny=NO, only allow users in this file # If userlist_deny=YES (default), never allow users in this file, and # do not even prompt for a password. # Note that the default vsftpd pam config also checks /etc/vsftpd.ftpusers # for users that are denied. root bin daemon adm 注意:要是想让这两个文件中的指定的那个用户login vsftpd server ,那么,就要在这两个文件中del relevant user, del one file in the user is nologin vsftpd server. 重点:file “/etc/vsftpd/vsftpd.conf “ and “/etc/vsftpd.user_list”是配合来用的.
One : vsftpd.conf relevant config. “Userlist_enable=YES” User_list file in the user nologin vsftpd server. NO in user_list file in the user can login vsftpd server. “Userlist_enable=NO” User_list file in the user can longin vsftpd server. But(但是)to del file vsftd.ftpusers in as (一样) the user. No in user_list file in the user no can login vsftpd server. 6. [root@michael ~]# ls -l /var/ftp <anonymous user login vsftpd the lord directory> total 8 drwxr-xr-x 2 root root 4096 May 24 2006 pub 7. [root@michael ~]# chkconfig --list vsftpd vsftpd 0:off 1:off 2:off 3:off 4:off 5:off 6:off [root@michael ~]# chkconfig --level 35 vsftpd on [root@michael ~]# chkconfig --level 35 vsftpd on [root@michael ~]# chkconfig --list vsftpd vsftpd 0:off 1:off 2:off 3:o |
凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢! |