I can't make vsftpd to work and it is driving me crazy. The virtual users can connect, but they can't upload files or create folders. I hope someone can help me.
I get this error in the ftp client:
553 Could not create file And this is the error in /var/log/messages
Jul 11 12:51:41 appserver kernel: type=1400 audit(1373557901.832:17): avc: denied { write } for pid=3705 comm="vsftpd" name="usr00" dev=dm-0 ino=2097155 scontext=unconfined_u:system_r:ftpd_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:default_t:s0 tclass=dir This is my vsftpd.conf:
pasv_enable=NO pam_service_name=vsftpd listen=YES anonymous_enable=NO local_enable=YES write_enable=YES local_umask=022 nopriv_user=vsftpd virtual_use_local_privs=YES guest_enable=YES user_sub_token=$USER local_root=/ftp/$USER chroot_local_user=YES hide_ids=YES guest_username=vsftpd This is my selinux configuration:
allow_ftpd_anon_write --> off allow_ftpd_full_access --> off allow_ftpd_use_cifs --> off allow_ftpd_use_nfs --> off ftp_home_dir --> on ftpd_connect_db --> off ftpd_use_passive_mode --> off httpd_enable_ftp_server --> off tftp_anon_write --> off The test user is usr00. There is a folder /ftp/usr00 :
ls -Z /ftp drwxr-xr-x. vsftpd vsftpd unconfined_u:object_r:default_t:s0 cg00