最近遇到一个奇怪的问题,有关linux selinux的设置问题
一个同学在配置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=disabled
也就是把SELINUXTYPE的值改成了disabled,结果发现服务器启动失败了
解决方法:
系统启动时候进入按e进入
找到下边这一行加上selinux=0
按键ctrl+x重启即可,正常进去之后修改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
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted