CentOS 6.8 method steps to install vsftpd

vsftpd is the abbreviation of "very secure FTP daemon", which is a completely free, source code ftp server software.

vsftpd is the most respected FTP server program in Linux distributions. It is small and light, safe and easy to use, supports virtual users, supports bandwidth restrictions and other functions.

System environment: CentOS 6.8 64 bit

vsftpd version: vsftpd-2.22-21.el6.x86_64

1. Excuting an order

yum -y install vsftpd

ps: (1) Whether to execute with sudo permissions is determined according to the specific environment; (2) rpm -qa | grep vsftpd can check whether vsftpd has been installed through this; (3) The default configuration file is in /etc/vsftpd/vsftpd.conf.

2. Create a new folder under the directory: /product/ftpfile/

**3. Add an anonymous user ftpuser, command: **

sudo useradd ftpuser -d /product/ftpfile -s /sbin/nologin

**4. Modify the permissions of the file ftpfile, command: **

sudo chown -R ftpuser.ftpuser ./ftpfile/

**5. Reset the password of ftpuser, command: **

sudo passed ftpuser

6. Enter the /etc/vsftpd directory, create a new file chroot_list, add content: ftpuser:

Add the newly created virtual user ftpuser to this configuration file, which will be referenced later.

**7. Create a new file index.html under the ftpfile folder and enter the content: **

this is a ftpfile demo
/ftpfile

8. Open the file in the /etc/vsftpd directory: vsftpd.conf, modify or add the following configuration:

local_root=/product/ftpfile
# chroot_local_user=YES
anon_root=/product/ftpfile
use_localtime=YES
# anonymous
# anonymous_enable=YES
anonymous_enable=NO
# pasv_enable=YES
pasv_min_port=61001
pasv_max_port=62000

9. Add configuration to the firewall:

Firewall location:

Add configuration:

# vsftpd
- A INPUT -p TCP --dport 61001:62000-j ACCEPT
- A OUTPUT -p TCP --sport 61001:62000-j ACCEPT

- A INPUT -p TCP --dport 20-j ACCEPT
- A OUTPUT -p TCP --sport 20-j ACCEPT
- A INPUT -p TCP --dport 21-j ACCEPT
- A OUTPUT -p TCP --sport 21-j ACCEPT

Restart the firewall:

sudo service iptables restart

Restart vsftpd:

sudo service vsftpd restart

ps: The first startup is Shutting down vsftp is failed. Don't care, because this is a restart command. Ensure that Starting vsftpd is OK, which means that the vsftpd service is successful.

**10. Modify the security group policy: sudo vi /etc/selinux/config, check to ensure that SELINUX=disabled. **

In order to avoid the 550 access denied error in the verification, enter the command:

sudo setsebool -P ftp_home_dir 1

11. Start the browser: ftp://120.77.86.200, enter the user name ftpuser and password xxx:

Commonly used commands:

sudo service vsftpd start #start up
sudo service vsftpd stop #shut down
sudo service vsftpd restart #Reboot

The above is the whole content of this article, I hope it will be helpful to everyone's study.

Recommended Posts

CentOS 6.8 method steps to install vsftpd
Centos7.6 method to install Tomcat-8.5.39
Centos6 method steps to build gitlab
Centos8 uses yum to install mongodb 4.2 method
Detailed steps to install centos on vmware10.0 cracked version
How to install jdk1.8 on centOS7
How to install MySQL on CentOS 8
Method steps to increase python font
How to upgrade CentOS7 to CentOS8 (detailed steps)
How to install Memcached on CentOS 8
How to install R on CentOS 8
How to install FFmpeg on CentOS 8
How to install Virtualbox on CentOS 8
How to install TensorFlow on CentOS 8
[Introduction to redis] Install redis under Centos
How to install TeamViewer on CentOS 8
How to install Perl 5 on CentOS
How to install Git on CentOS 8
How to install PHP7.4 in CentOS
How to install Gradle on CentOS 8
How to install Elasticsearch on CentOS 8
How to install Jenkins on CentOS 8
How to install Java on CentOS 8
How to install Go on CentOS 8
Linux CentOS 7 install JDK detailed steps
How to install GCC on CentOS 8
How to install Yarn on CentOS 8
How to install Asterisk on CentOS 7
How to install Jenkins on CentOS 8
How to install Python 3.8 on CentOS 8
How to install Tomcat 9 on CentOS 8
How to install Webmin on CentOS 8
How to install Ruby on CentOS 8
How to install Skype on CentOS 8
How to install htop on CentOS 8
How to install Python on CentOS 8
How to install Elasticsearch on CentOS 8
How to install Postgresql on CentOS 8
How to install Wordpress on Centos
How to install htop on CentOS 8
centos7 .*tar package to install MySQL5.7
How to install TeamViewer on CentOS 8
How to install MariaDB on CentOS 8
How to install Odoo 13 on CentOS 8
How to install Apache on CentOS 8
How to install OpenCV on CentOS 8
How to install PHP on CentOS 8
Use VMware15 to install Linux (CentOS6.5)
How to install MongoDB on CentOS 8
Detailed steps to install and configure k8s cluster in centos 7
Detailed steps to install virtual machines with VMware 15 and use CentOS 8
Centos8 uses Apache httpd2.4.37 to install web server steps in detail
How to install Android SDK in centos7
Graphic KVM to install CentOS7.6 operating system
ubuntu16.04 method steps to upgrade the kernel
Centos install sshfs to achieve mount directory
How to install Apache Maven on CentOS 8
How to install Apache Kafka on CentOS 7
R&D: How To Install Python 3 on CentOS 7
Ubuntu20.04 steps to install cuda10.1 (graphic tutorial)
How to install GCC compiler on CentOS 7