728x90
반응형

리눅스 SELinux 변경 이후  리눅스 재부팅시 에러 해결 방법 

  • 부팅시 Failed to load SELinux policy, freezing. 에러 발생 

 

/etc/selinux/config   파일을 수정이후 부팅이 실패 할 경우 

[root@centos7:/root]$ 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 - SELinux is fully disabled.
SELINUX=enforcing
# SELINUXTYPE= type of policy in use. Possible values are:
#       targeted - Only targeted network daemons are protected.
#       strict - Full SELinux protection.
SELINUXTYPE=targeted
[root@centos7:/root]$

 

  • 부팅 화면에서 키보드 e 를 누르고 

  • selinux=0 추가 후 재부팅
  • Ctrl + x  를 누르면 다시 부팅이 된다. 

 

 

SELinux 란? 

SELinux(보안 강화 리눅스)는 리눅스 운영 체제의 보안 기능 중 하나로, 프로세스, 파일 및 네트워크에 대한 접근을 제어하는 매커니즘입니다. SELinux는 NSA(미국 국가 안보국)와 레드햇이 공동으로 개발한 프로젝트로, 리눅스 커널에 포함되어 있습니다.

 

  • /etc/selinux/config 파라미터 설명 
    • enforcing 모드: 모든 SELinux 정책이 적용되고 보안 위반이 감지되면 해당 작업이 차단됩니다.
    • permissive 모드: SELinux는 로그를 기록하지만 작업을 차단하지는 않습니다.
    • disabled 모드: SELinux가 완전히 비활성화됩니다.
728x90
반응형

+ Recent posts