Enable the FTP (vsftpd) service in Linux

Source: Internet
Author: User
Tags ftp login ftp transfer

Enable the FTP (vsftpd) service in Linux
1. check whether it is installed # rpm-qa | grep vsftpd 2. new Installation # rpm-ivh vsftpd-2.0.1-5.i386.rpm 3. start/stop/restart # service vsftpd start # service vsftpd stop # service vsftpd restart 4. main configuration file # vi/etc/vsftpd. conf # configure anonymous_enable = YES for anonymous users # whether anonymous ftp is allowed, otherwise, select NO anon_upload_enable = YES # Can anonymous users upload anon_mkdir_write_enable = YES # Can anonymous users create directories anon_other_write_enable = YES # Modify file names and delete files # local_enable = YES # allow local users to log on to loca Rochelle umask = 022 # umask default 755 write_enable = YES chroot_local_user = YES # chroot_list_enable = YES # Do You Want To restrict system users to chroot_list_file in your home directory? =/etc /vsftpd. chroot_list # list of non-chroot users. chown_upload = YES # Whether to change the chown_username = username # If you need to enter a system username userlist_enable = YES userlist_deny = NO deny_email_enable = YES # whether anonymous users are allowed to use certain email addresses banned_email_file =/etc/vsftpd. banned_emails # disable the file path of the email address ftp D_banner = Welcome to chenlf FTP service. # customize the welcome information dirmessage_enable = YES # Whether to display the directory description file, which must be created by submitting a ticket. message file message_file = # Set the file name of the directory information file obtained when accessing a directory. The default value is. message xferlog_enable = YES # Whether to record the ftp Transfer Process xferlog_file =/var/log/vsftpd. log # ftp transfer log path and name xferlog_std_format = YES # use standard ftp xferlog mode ascii_upload_enable = YES # use ascii code to upload files ascii_download_enable = YES # use ascii code download the connect_from_port_20 = YES # Are you sure you want Port transfer comes from 20 (ftp-data) nopriv_user = ft1_cure # The non-privileged system user required to run vsftpd is nobody async_abor_enable = YES by default # whether to allow special ftp command async ABOR. # FTP server resource limit idle_session_timeout = 600 # Set the session Timeout value data_connection_timeout = 120 # Set the data transmission timeout value max_clients = 50 # the maximum number of user connections is 0 by default. max_per_ip = 5 # Each maximum number of connections from an IP address anon_max_rate = 102400 # anonymous download speed KB local_max_rate = 102400 # normal user download speed KB 5. other configuration files/etc/xinetd. d/vsftpd service ftp {socket _ Type = stream wait = no user = root server =/usr/local/sbin/vsftpd # server_args = # log_on_success + = duration userid # log_on_failure + = USERID nice = 10 disable = no} /etc/pam. d/vsftpd PAM Authentication/etc/vsftpd. chroot_list this file contains the username that has permissions on all FTP content on the server. For other users, their home directories on the server are displayed as root directories. /Etc/shells checks whether a valid user shell exists by default before allowing local users to log on. In case of PAM Authentication unavailability. /Etc/ftpusers this file contains * forbidden * FTP login username, usually "root", "uucp", "news" and so on, because these user permissions are too high, it is highly risky to log on to FTP due to misoperations. 6. firewall settings if you are using the default SuSEFirewall2, In the YaST-system-/etc/sysconfig Editor, The network-SuSEfirewall2 adds ftp to FW_SERVICES_EXT_TCP, for example, if you want to enable ssh, then FW_SERVICES_EXT_TCP "ftp ssh". If you need passive mode FTP and nat, In the YaST-system-/etc/sysconfig editor, network-SuSEfirewall2 FW_LOAD_MODULES "ip_conntrack_ftp ip_nat_ftp" another way to directly modify the firewall configuration file: # cd/etc/sysconfig/# vi SuSEfirewall2 restart "ftp 21 telnet 23" # rcSuSEfirewall2 restart

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.