How to enable/disable SELinux on a server

  1. Connect to a server via SSH.

  2. Open the /etc/selinux/config file in any text editor. In this example, we are using the vi utility:

    # vi /etc/selinux/config

  3. Change the SELINUX value to:

    • disabled to completely turn off SELinux on the server:

      SELINUX=disabled

    • permissive to make SELinux print warnings instead of enforce security policy:

      SELINUX=permissive

    • enforcing to make SELinux security policy enforced:

      SELINUX=enforcing

  4. Save the changes and close the file.

    Note: A server restart is required to apply these changes.

  5. Check the permanent status of SELinux:

    # sestatus | grep "Mode from config file"
    Mode from config file: permissive

  • plesk
  • 4 Users Found This Useful
Was this answer helpful?

Related Articles

Connecting using PuTTY on Windows workstations

Configuring PuTTY In PuTTY, under Session, enter your Host Name Under Connection choose Data...

How to install the php-mcrypt module on a Plesk server

Question How to install the php-mcrypt module on a Plesk server? Answer Notes: The solution in...

Windows: Accessing Your Server with Remote Desktop

This article explains how to use Remote Desktop to access your Windows server’s desktop from...

What is Reverse DNS?

Reverse DNS (rDNS) is name resolution that looks up an IP addresses to obtain a domain name,...

What is Reverse DNS?

Reverse DNS (rDNS) is name resolution that looks up an IP addresses to obtain a domain name,...