How to Disable SELinux

In the command line type the following as root

# echo 0 >/selinux/enforce

We can also use the setenforce command to effectively disable it as below
# setenforce Permissive


# setenforce 0

With the above command selinux will be turned off temporarily. But to permanently disable it we have to edit /etc/sysconfig/selinux as below

vi /etc/sysconfig/selinux

and  change as below


And then you can try rebooting your machine. The above command are for CentOS/RedHat/Fedora machines




Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s