1.部署ftp服务
在/etc/sysconfig/selinux 中
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=disabled 将此处修改为disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# minimum - Modification of targeted policy. Only selected processes are protected.
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
~
~
配置完成后必须重新启动虚拟机
reboot
2.安装ftp
yum install vsftpd -y 下载vsftpd
systemctl start vsftpd 开启ftp服务
systemctl stop firewalld 关闭火墙
systemctl enable vsftpd 开机自动开启ftp服务
netstat -antlupe | grep vsftpd #查看ftp端口是否成功开启
firewall-cmd –list-all 查看防火墙
firewall-cmd –permanent –add-service=ftp 在防火墙允许列表中添加ftp服务
firewall-cmd –reload 更新防火墙规则
[root@localhost ~]# yum install vsftpd -y
Loaded plugins: langpacks
Resolving Dependencies
--> Running transaction check
---> Package vsftpd.