CentOS 永久关闭SELinux

余生长醉 提交于 2019-12-07 18:49:52

CentOS 永久关闭SELinux

[root@lujie ~]# vim /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=enforcing

# SELINUXTYPE= can take one of these two values:

# targeted - Targeted processes are protected,

mls - Multi Level Security protection.

#SELINUXTYPE=targeted

设置方法:

1 #SELINUX=enforcing #注释掉

2 #SELINUXTYPE=targeted #注释掉

3 SELINUX=disabled #增加

4 :wq #保存,关闭。

shutdown -r now #重启

完整修改后如下:

# 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

# SELINUXTYPE= can take one of these two values:

# targeted - Targeted processes are protected,

mls - Multi Level Security protection.

#SELINUXTYPE=targeted

SELINUX=disabled

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!