Turn off the SELinux feature
1. First check the status of the SELinux , command:getenforce
[Email protected] ~]# Getenforce Disabled
view selinux config file, command: cat/etc/selinux/config
# 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
3. Change the selinux=enforced to selinux=disabled
method 1:VI Editor modification
method 2 sed sed –i   " s#selinux= #SELINUX = '
4. The modified file requires a reboot to take effect, but the enterprise Server cannot be restarted for up to a few hours. So you need another way, you can use the setenforce command to set the temporary effective shutdown without restarting the effect.
command: s Etenforce 0
This article is from the "Flag of Linux Road" blog, please be sure to keep this source http://chenmingqi.blog.51cto.com/8942827/1887148
Turn off SELinux functionality