Not able to disable SELinux

Support for security such as Firewalls and securing linux
Post Reply
Vamsi158
Posts: 5
Joined: 2016/10/14 07:52:17

Not able to disable SELinux

Post by Vamsi158 » 2016/10/18 06:59:46

hi Team,

I am new to Linux.
I installed centos 6.7 in minimal mode which I got from http://archive.kernel.org/centos-vault/ ... 64-minimal.
I wanted to disable SELinux to allow my application get installed.
but after rebooting again SElinux is enabling.
Please help how to disable/remove it permanently.

[root@master ~]# cat /etc/sysconfig/selinux

# 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.


[root@master ~]# 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.

[root@master ~]# cat /etc/sysconfig/grub
boot=/dev/sda
forcelba=0

[root@master ~]# cat /boot/grub/grub.conf
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/mapper/vg_master-lv_root
# initrd /initrd-[generic-]version.img
#boot=/dev/sda
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title CentOS 6 (2.6.32-573.el6.x86_64)
root (hd0,0)
kernel /vmlinuz-2.6.32-573.el6.x86_64 ro root=/dev/mapper/vg_master-lv_root rd_NO_LUKS KEYBOARDTYPE=pc KEYTABLE=us LANG=en_US.UTF-8 rd_NO_MD rd_LVM_LV=vg_master/lv_swap SYSFONT=latarcyrheb-sun16 crashkernel=auto rd_LVM_LV=vg_master/lv_root rd_NO_DM rhgb quiet
initrd /initramfs-2.6.32-573.el6.x86_64.img
GRUB_CMDLINE_LINUX="selinux=0" -- I only added this to give a try.

after rebooting still it is showing selinux is enabled.

[root@master ~]# sestatus
SELinux status: enabled
SELinuxfs mount: /selinux
Current mode: permissive
Mode from config file: error (Success)
Policy version: 24
Policy from config file: targeted
[root@master ~]#

my application is throwing error like :
SELinux is enabled.It must be disabled to install and use this product.

Please help me.

Thanks.

User avatar
TrevorH
Forum Moderator
Posts: 26942
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Not able to disable SELinux

Post by TrevorH » 2016/10/18 07:51:16

If your app is saying that then it's broken and should not be used. Do not allow a software vendor to dictate to you that you should disable one of the integral parts of system security.

Also, do not run 6.7, it's unsupported. Run yum update to get your system up to date. Only 6.8 is current.
CentOS 5 died in March 2017 - migrate NOW!
CentOS 6 goes EOL sooner rather than later, get upgrading!
Full time Geek, part time moderator. Use the FAQ Luke

enjinn
Posts: 8
Joined: 2016/10/25 18:16:52

Re: Not able to disable SELinux

Post by enjinn » 2016/10/25 21:29:31

First, I happen to agree with the above poster.

However, what does the getenforce command state is the status of your selinux? And did you perform a reboot after changing it to disabled?

Post Reply

Return to “CentOS 6 - Security Support”