Baza znanja

How to Disable SELinux Status in CentOS 7?

  • 45

Check SELinux Status:

First login as a root on centOS7.

Now check the status of SELinux by following command.
sestatus


If it is already disabled, then there is no need to disable it on the other hand if this screen displayed in front of you then follow the below given steps.

Disable SELinux:

To permanently disable SELinux on CentOS 7 system, follow the steps below:

  1. Open the /etc/selinux/config file and edit the SELINUX mod to disabled.

vi /etc/selinux/config

this will show you the image like given below. 


As the above image shows that it is enabled now press “i” to insert or edit this file now navigate to this line and write “disabled”Then press “Esc” after that press “shift+z+z” to save changes.

   

  1. Save the file and reboot your CentOS system with.

reboot

  1. After reboot verify the change with the sestatus command:

sestatus

The output should look like this:



Now your SELinux is disabled.

 

be sure to check out more articles on Linux Boost  some of links How to Install vim on CentOS 7 and How to Install nano on CentOS


Je li Vam ovaj odgovor pomogao?