配置好yum源,后如下安装
# yum list vsftpd
Loaded plugins: fastestmirror, security
Loading mirror speeds from cached hostfile
Available Packages
vsftpd.x86_64 2.2.2-11.el6_4.1
# yum install vsftpd.x86_64
……
编辑配置文件vsftpd.conf
# cd /etc/vsftpd/
# cp vsftpd.conf vsftpd.conf.bak
# vim vsftpd.conf
做如下配置:
“#anonymous_enable=YES” 改成 “anonymous_enable=NO”
文件末尾新增:userlist_deny=NO
说明:仅允许userlist的用户访问ftp服务器
创建ftp用户
# useradd testacc
# passwd testacc
Changing password for user testacc.
New password:
BAD PASSWORD: it is too simplistic/systematic
Retype new password:
passwd: all authentication tokens updated successfully.
# echo testacc >> /etc/vsftpd/user_list
说明:也可以通过编辑配置文件user_list,在文件末尾新增添加的用户
在/etc/vsftpd/vsftpd.conf 里添加:
chroot_list_enable=YES //使用户不能离开主目录
chroot_list_file=/etc/vsftpd/chroot_list重启ftp服务器
然后在 /etc/vsftpd/chroot_list里添加ftpuser,每个一行。
类似如下:
ftpusr1
ftpusr2
...
/etc/vsftpd/userlist 里添加:
ftpusr1
ftpusr2
...
# service vsftpd restart
北京java找工作群145471323
# yum list vsftpd
Loaded plugins: fastestmirror, security
Loading mirror speeds from cached hostfile
Available Packages
vsftpd.x86_64 2.2.2-11.el6_4.1
# yum install vsftpd.x86_64
……
编辑配置文件vsftpd.conf
# cd /etc/vsftpd/
# cp vsftpd.conf vsftpd.conf.bak
# vim vsftpd.conf
做如下配置:
“#anonymous_enable=YES” 改成 “anonymous_enable=NO”
文件末尾新增:userlist_deny=NO
说明:仅允许userlist的用户访问ftp服务器
创建ftp用户
# useradd testacc
# passwd testacc
Changing password for user testacc.
New password:
BAD PASSWORD: it is too simplistic/systematic
Retype new password:
passwd: all authentication tokens updated successfully.
# echo testacc >> /etc/vsftpd/user_list
说明:也可以通过编辑配置文件user_list,在文件末尾新增添加的用户
在/etc/vsftpd/vsftpd.conf 里添加:
chroot_list_enable=YES //使用户不能离开主目录
chroot_list_file=/etc/vsftpd/chroot_list重启ftp服务器
然后在 /etc/vsftpd/chroot_list里添加ftpuser,每个一行。
类似如下:
ftpusr1
ftpusr2
...
/etc/vsftpd/userlist 里添加:
ftpusr1
ftpusr2
...
# service vsftpd restart
北京java找工作群145471323