查看SELinux状态/usr/sbin/sestatus -vgetenforce or cat /sys/fs/selinux/enforceA value of 1 means SELinux is in enforcing mode.A value of 0 means SELinux is in permissive mode.关闭SELinux1、临时关闭不用重启机器设置SELinux 成为permissive模式 setenforce 0设置SELinux 成为enforcing模式setenforce 12、修改配置文件需要重启机器修改/etc/selinux/config 文件将SELINUXenforcing改为SELINUXdisabled重启机器即可Disable SELinux脚本如下:setenforce 0 sed -i s/^SELINUX.*/SELINUXdisabled/ /etc/selinux/config
selinux管理
查看SELinux状态/usr/sbin/sestatus -vgetenforce or cat /sys/fs/selinux/enforceA value of 1 means SELinux is in enforcing mode.A value of 0 means SELinux is in permissive mode.关闭SELinux1、临时关闭不用重启机器设置SELinux 成为permissive模式 setenforce 0设置SELinux 成为enforcing模式setenforce 12、修改配置文件需要重启机器修改/etc/selinux/config 文件将SELINUXenforcing改为SELINUXdisabled重启机器即可Disable SELinux脚本如下:setenforce 0 sed -i s/^SELINUX.*/SELINUXdisabled/ /etc/selinux/config