Verificar a versão :
[root@localhost ~]# cat /etc/redhat-release
CentOS release 6.4 (Final)
Verificar o estado do SELINUX:
[root@localhost ~]# sestatus
SELinux status: enabled
SELinuxfs mount: /selinux
Current mode: enforcing
Mode from config file: enforcing
Policy version: 24
Policy from config file: targeted
Visulizar o ficheiro de configuração:
[root@localhost ~]# 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=enforcing
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
Editar o ficheiro e alterar a configuração para:
vi /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.
SELINUXTYPE=targeted
Reeiniciar o servidor:
[root@localhost ~]# init 6
Verificar estado do SELINUX após reeniciar:
[root@exp01centos ~]# sestatus
SELinux status: disabled
É necessário efectuar os passos descritos em modo root.
Com um GUI
- System --> Administration --> Security Level and Firewall
- Selecionar Selinux
- Selecionar Disabled e reiniciar o servidor.
As instruções são válidas para o RHEL 6.4