Saturday, 30 September 2017

[CentOS] Setup FTP when SElinux is enabled

1. Set FTP User home directory (FTP 유저 홈디렉터리 설정)

#> chown -R ftp:ftp /var/ftp
#> semanage fcontext -a -t public_content_rw_t /var/ftp
#> restorecon -Rvv /var/ftp
#> setsebool -P ftp_home_dir 1
#> setsebool -P ftpd_full_access 1
#> ls -lZ /var | grep ftp




2. Restart FTP service

# Set FTP service auto enable
#> systemctl enable vsftpd

# Restart FTP Server
#> systemctl restart vsftpd

No comments:

Post a Comment