Centos 7如何临时和永久关闭selinux
永久关闭selinux方法2
-
运行命令
sudo sed -i ‘s/SELINUX=enforcing/SELINUX=disabled/’ /etc/selinux/config
将 /etc/selinux/config 文件中
SELINUX=enforcing
替换为
SELINUX=disabled
运行命令
sudo grep SELINUX=disabled /etc/selinux/config
显示
SELINUX=disabled
确认替换修改成功
reboot
-
重启后 运行命令 sestatus
SELinux status : disabled
永久关闭selinux成功
Enjoy it !!!
Leave a reply