1. See if VSFTP is installed
Rpm-qa | grep vsftpd
If Vsftpd-2.0.5-21.el5 appears, you have installed Vsftp
2. Download VSFTPD:
ftp://rpmfind.net/linux/centos/6.7/os/x86_64/Packages/vsftpd-2.2.2-14.el6.x86_64.rpm
Source: http://rpmfind.net/linux/rpm2html/search.php?query=vsftpd (x86-64)
3, Installation vsftpd
RPM-IVH vsftpd-2.2.2-11.el6.x86_64.rpm
4. Test whether the installation is successful
[[Email protected] ~] #service vsftpd Start
For vsftpd start vsftpd:[OK]
5, Configuration vsftpd
# Whereis VSFTPD
VSFTPD:/usr/sbin/vsftpd/etc/vsftpd/usr/share/man/man8/vsftpd.8.gz
Yum installs the main directory for the above 3 directories, where the configuration file vsftpd.conf in/etc/vsftpd, see below How to configure vsftpd.conf
# Default Profile:/etc/vsftpd.conf
Backup: CP vsftpd.conf Vsftpd.conf_bak
Editor: Vim vsftpd.conf
# Here are the options and instructions for configuring
######### Core Settings ###########
# allow local users to log on
Local_enable=yes
# Write permissions for Local Users
Write_enable=yes
# Local file permissions using FTP, default to 077
# generally set to 022
local_umask=022
# when switching directories
# whether to display the contents of the. Message in the directory
Dirmessage_enable=yes
Dirlist_enable = NO
#验证方式
#pam_service_name =vsftpd
# Enable data connections for FTP data ports
Connect_from_port_20=yes
# Run as a standalone FTP service
Listen=yes
# Modify the connection port
#listen_port =2121
######### Anonymous Login Settings ###########
# Allow Anonymous Logon
Anonymous_enable=no
# If Anonymous Logon is allowed
# Whether to turn on anonymous upload permission
#anon_upload_enable =yes
# If Anonymous Logon is allowed
# whether to allow anonymous folder creation and upload files within folders
#anon_mkdir_write_enable =yes
# If Anonymous Logon is allowed
# Anonymous accounts can have delete permissions
#anon_other_write_enable =yes
# If Anonymous Logon is allowed
# Anonymous Download permissions
# Anonymous for other, can set directory/File attribute control
#anon_world_readable_only =no
# If Anonymous Logon is allowed
# Limit anonymous user transfer rate, Unit bite
#anon_max_rate =30000
######### User throttling Settings ###########
# # # Limit Login
# Use UserList to restrict user access
#userlist_enable =yes
# People in the list are not allowed to visit
#userlist_deny =no
# Limit the path to the list file placement
#userlist_file =/etc/vsftpd/userlist_deny.chroot
# # # Limit Directory
# Restrict all users to the home directory
#chroot_local_user =yes
# Call a list of users who restrict home directories
Chroot_list_enable=yes
# Limit the path to the list of users in your home directory
Chroot_list_file=/etc/vsftpd/chroot_list
######### Log Settings ###########
# Log file path settings
Xferlog_file=/var/log/vsftpd.log
# activate the upload/download log
Xferlog_enable=yes
# Use the standard log format
#xferlog_std_format =yes
######### Security Settings ###########
# User Idle timeout, per second
#idle_session_timeout =600
# Data Connection idle timeout, per second
#data_connection_timeout =120
# Disconnect the client after 1 minutes of idle
#accept_timeout =60
# Reconnect after 1 minutes of interruption
#connect_timeout =60
# Local user transfer rate, Unit bite
#local_max_rate =50000
# Maximum number of connections for FTP
#max_clients =200
# Maximum number of connections per IP
#max_per_ip =5
######### Passive Mode setting ###########
# Whether to open a passive mode
Pasv_enable=yes
# Passive Mode min port
pasv_min_port=5000
# Passive Mode maximum port
pasv_max_port=6000
######### Other Settings ###########
# Welcome Information
Ftpd_banner=welcome to FTP server!
4 Add an FTP firewall rule:
/sbin/iptables-i input-p TCP--dport 21-j ACCEPT
/etc/rc.d/init.d/iptables Save
/etc/init.d/iptables restart
5 Add Users (note that the Nologin type user Ftpuser is added here):
useradd-d/home/ftp-s/sbin/nologin Ftpuser
If VSFTPD is started, restart
Pkill VSFTPD/USR/SBIN/VSFTPD &
Reference:
Http://www.cnblogs.com/itech/archive/2012/09/16/2687378.html
Http://www.linuxidc.com/Linux/2015-01/111964.htm
Http://jingyan.baidu.com/album/03b2f78c771db45ea237ae28.html?picindex=1
http://shuany.iteye.com/blog/850568
centos6.5 offline installation of FTP service