歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux基礎 >> Linux基礎知識

SELinux拒絕vsftpd上傳文件到用戶主目錄

系統是CentOS 5.1,創建用戶後,不能登陸FTP,在/var/log/messages文件記錄以下信息:

    Mar 31 13:46:15 localhost kernel: audit(1206942375.697:5719): avc: denIEd { append } for pid=32111 comm="vsftpd" name="test" dev=sda3 ino=19400200 scontext=root:system_r:FTPd_t:s0 tcontext=root:object_r:root_t:s0 tclass=file

    SELinux FTP daemon policy is customizable based on least Access required. So by default SELinux does not allow users to login and read their home directorIEs.

    If you are setting up this Machine as a FTPd server and wish to allow users to Access their home directororIEs, you need to set the FTP_home_dir boolean.

    執行命令:

    setsebool -P FTP_home_dir 1

    上傳文件成功。

Copyright © Linux教程網 All Rights Reserved