vim /etc/selinux/config
SELINUX=disabled
reboot
service iptables stop
rpm -qa vsftpd
yum install -y vsftpd
service vsftpd start
chkconfig --level 35 vsftpd on
cd /etc/vsftpd/
cp vsftpd.conf vsftpd.conf.bak
vim vsftpd.conf
anonymous_enable=NO
chroot_local_user=YES
chroot_list_enable=YES
chroot_list_file=/etc/vsftpd/chroot_list
vim chroot_list
groupadd www
useradd www -g www
mkdir -p /usr/local/apache/htdocs
cd /usr/local/apache
chmod -R 775 htdocs/
chown -R www:www /usr/local/apache
useradd ftp1 -g www -s /sbin/nologin -d /usr/local/apache/htdocs -M
passwd ftp1
service vsftpd restart
时间: 2024-10-13 13:00:19