首页 > 系统服务 > 详细

CentOS7 关闭selinux

时间:2018-06-14 12:16:32      阅读:223      评论:0      收藏:0      [点我收藏+]

SELinux, an abbreviation of Security-Enhanced Linux, is a security enhancement to the Linux operating system. It is a labeling system that blocks many system functions in its default configuration.

SELinux is very useful for some users, but due to its administrative overhead, you may be better off simply disabling it. The time spent adding rules and updating permissions on SELinux versus the added security benefit may not be worth it.

First check if SELinux is disabled or enabled:

sestatus

If this command returns "SELinux status: enabled", you can disable SELinux with the following command.

setenforce 0

The command above will only disable SELinux for now, but the change will be reverted across reboots. Therefore, disable it permanently by opening the file /etc/sysconfig/selinux and replace the current SELINUX directive with a value of disabled so it looks like this:

vim /etc/sysconfig/selinux
SELINUX=disabled

Check the SELinux status again to make sure that it has been properly disabled.

sestatus

CentOS7 关闭selinux

原文:https://www.cnblogs.com/lionetchen/p/9182438.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!