关闭防火墙
查看防火墙状态
systemctl status firewalld.service
关闭防火墙
systemctl stop firewalld.service
关闭防火墙开机启动
systemctl disable firewalld.service
关闭SELinux
查看SELinux状态
getenforce
临时关闭SELinux
setenforce 0
临时打开SELinux
setenforce 1
永久关闭SELinux
将SELINUX=enforcing改为SELINUX=disabled,保存后退出后,下次SELinux就不会启动了
vim /etc/selinux/config # 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=enforcing SELINUX=disable # SELINUXTYPE= can take one of three values: # targeted - Targeted processes are protected, # minimum - Modification of targeted policy. only selected processes are protected. # mls - Multi Level Security protection. SELINUXTYPE=targeted



