Turn off SELinux functionality

Source: Internet
Author: User

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

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.