linux 15秒 搭建VSFTPD文件服务器
生活随笔
收集整理的這篇文章主要介紹了
linux 15秒 搭建VSFTPD文件服务器
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
文章目錄
- 1. 在線安裝
- 2. 創建用戶
- 3. 限制用戶活動范圍
- 4. 添加用戶管制
- 5. 關閉匿名訪問
- 6. 編輯一個安全文件
- 7. 重新啟動vsftpd
- 8. 客戶端測試
- 9. 本機測試
- 10. 再次本機測試
1. 在線安裝
yum install vsftpd2. 創建用戶
useradd ftpuser passwd ftpuser3. 限制用戶活動范圍
vim vsftpd.conf 打開102和104行注釋 chroot_list_enable=YES # (default follows) chroot_list_file=/etc/vsftpd/chroot_list4. 添加用戶管制
vim chroot_list 把新建的ftpuser添加進去5. 關閉匿名訪問
anonymous_enable=YES 修改為anonymous_enable=NO6. 編輯一個安全文件
將SELINUX=enforcing修改為SELINUX=disable#使配置生效setenforce 07. 重新啟動vsftpd
service vsftpd restart8. 客戶端測試
500 OOPS: vsftpd: refusing to run with writable root inside chroot()
解決方案
9. 本機測試
[root@localhost ~]# ftp 192.168.0.110 -bash: ftp: command not found [root@localhost ~]#解決方案:
yum install ftp10. 再次本機測試
[root@localhost ~]# ftp 192.168.0.110 Connected to 192.168.0.110 (192.168.0.110). 220 (vsFTPd 3.0.2) Name (192.168.0.110:root): ftpuser 331 Please specify the password. Password: 230 Login successful. Remote system type is UNIX. Using binary mode to transfer files. ftp> ls 227 Entering Passive Mode (192,168,0,110,78,56). 150 Here comes the directory listing. drwxr-xr-x 2 1002 1002 6 Dec 26 10:44 2020-12-26 226 Directory send OK. ftp> exit 221 Goodbye. [root@localhost ~]#總結
以上是生活随笔為你收集整理的linux 15秒 搭建VSFTPD文件服务器的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: SpringBoot2 集成 xxl-j
- 下一篇: webservice标签