歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> 關於Linux >> Redhat 5 Vsftp 550 failed to change directory問題解決

Redhat 5 Vsftp 550 failed to change directory問題解決

日期:2017/3/1 17:02:32   编辑:關於Linux
Redhat 5 Vsftp 550 failed to change directory問題解決 結果測試的時候發現 ftp localhost ftp> cd cdrom 550 Failed to change directory. 無法切換目錄到/pub/cdrom www.2cto.com 原因是SElinux的FTP傳輸審核功能禁止切換目錄 解決辦法: 1. /etc/sysconfig/selinux上禁用之,重啟Linux生效 2. 不重啟linux,臨時停用selinux的辦法, 1 /usr/sbin/setenforce 0 3. 禁用SElinux的FTP傳輸審核功能 www.2cto.com 1 /usr/sbin/setsebool -P ftpd_disable_trans 2 service vsftpd restart 使用getsebool -a | grep ftp命令找到ftp的bool值 匿名上傳setsebool -P allow_ftpd_anon_write on 禁用ftp傳輸審核setsebool -P ftpd_disable_trans on 01 sestatus 02 [root@xen ~]# sestatus 03 SELinux status: enabled 04 SELinuxfs mount: /selinux 05 Current mode: permissive 06 Mode from config file: enforcing 07 Policy version: 21 08 Policy from config file: targeted 09 10 [root@xen ~]# getsebool -a | grep ftp 11 allow_ftpd_anon_write --> off 12 allow_ftpd_full_access --> off 13 allow_ftpd_use_cifs --> off 14 allow_ftpd_use_nfs --> off 15 allow_tftp_anon_write --> off 16 ftp_home_dir --> off 17 ftpd_disable_trans --> off 18 ftpd_is_daemon --> on 19 httpd_enable_ftp_server --> off 20 tftpd_disable_trans --> off 21 [root@xen ~]# setsebool -P ftpd_disable_trans on 22 [root@xen ~]# service vsftpd restart
Copyright © Linux教程網 All Rights Reserved