Disable SELinux on CentOS 7 / RHEL 7 / Fedora Linux

w‮al.ww‬utturi.com
Disable SELinux on CentOS 7 / RHEL 7 / Fedora Linux

To disable SELinux on CentOS 7 / RHEL 7 / Fedora Linux, follow these steps:

  1. Edit the /etc/selinux/config file:
sudo vi /etc/selinux/config
  1. Change the SELINUX setting to disabled. The line should look like this:
SELINUX=disabled
  1. Save the file and exit the editor.

  2. Reboot your system for the changes to take effect.

  3. To verify that SELinux is disabled, run the following command:

sestatus

The output should show that SELinux is disabled.

SELinux status:                 disabled

Keep in mind that disabling SELinux can compromise the security of your system. It is generally recommended to leave SELinux enabled and use it to enforce security policies, rather than disabling it. If you do need to disable SELinux, make sure you understand the security implications and take appropriate measures to secure your system.

Created Time:2017-10-28 14:02:28  Author:lautturi