linux system installed VSFTPD

Step 1: mounting assembly vsftpd
# yum -y install vsftpd
after installation, there /etc/vsftpd/vsftpd.conf file is vsftpd profile.
Step 2: Add a ftp user
# useradd ftpuser
# passwd ftpuser
such a user you've created, you can use this login, remember to use common logon do not use the anonymity. The default login path for the / home / ftpuser.
Step 3: firewall turned 21 port
# vim / etc / sysconfig / iptables
# Service iptables restart
Step 4: Modify the selinux
outside the network can access up, but could not find Back to Contents ( use the ftp active mode, passive mode or can not access, or upload can not, because selinux mischief.
---- ------------------ modify selinux
# setsebool -P allow_ftpd_full_access ON
# setsebool -P ftp_home_dir ON
---- ------------------ view SELinux
# getsebool -a | grep the FTP
allow_ftpd_anon_write -> OFF
allow_ftpd_full_access -> OFF
allow_ftpd_use_cifs - -> off
allow_ftpd_use_nfs --> off
ftp_home_dir --> off
ftpd_connect_db --> off
ftpd_use_passive_mode --> off
httpd_enable_ftp_server --> off
tftp_anon_write --> off

Step 5: Close anonymous access
# vim /etc/vsftpd/vsftpd.conf
put into anonymous_enable = YES NO = anonymous_enable
# the vsftpd the restart-Service

Step 6: Passive Mode Open
Description:
is enabled by default, but to specify a range of ports, vsftpd.conf open file, followed by the
pasv_min_port = 30,000
pasv_max_port = 30999
indicates the port range of 30000 to 30999, this can be freely changed.
Execute the command:
# vim /etc/vsftpd/vsftpd.conf
at the end add: pasv_min_port = 30,000 pasv_max_port = 30999
# Service vsftpd restart
# vim / etc / sysconfig / iptables
here to join: 30000: 30999 Port Development
# service iptables restart

Step 7: Setting the FTP boot vsftpd
# chkconfig vsftpd ON

Step 8: Test vsftpd
in the browser input:
the FTP: // ftpuser: [email protected]
ftp://192.168.139.131

Published 20 original articles · won praise 0 · views 1206

Guess you like

Origin blog.csdn.net/jinhuding/article/details/104988283