Page 1 of 1

SELinux labels and policies disappeared after update

Posted: 2015/04/06 14:31:56
by takane2
Hello all,

This weekend I ran a yum update on my server and the selinux-policy and selinux-policy-targeted packages were updated from 3.12.1-153 to 3.13.1-23. After the update was complete I found that all the polices and labels that I had put in place myself were gone! Is this expected behavior?

Re: SELinux labels and policies disappeared after update

Posted: 2015/04/07 19:04:53
by aks
Probably - if you didn't "tell" SElinux about your changes - if you just went in and modified the contexts on disk. On a relabel SElinux will re-label with what it know (not what's there already).

Re: SELinux labels and policies disappeared after update

Posted: 2015/04/07 19:36:37
by takane2
I used 'semanage fcontext' and restorecon to set them. Is there an additional step I am supposed to take?

Re: SELinux labels and policies disappeared after update

Posted: 2015/04/08 16:17:43
by aks
I don't think so - semanage should update the contexts persistently. I'd guess that something got overwritten with the update - so check the actual files.
For more information about where to check see: https://access.redhat.com/documentation ... ntext.html