SElinux notes

From Wiki
Revision as of 13:59, 14 October 2014 by Admin (Talk | contribs)

Jump to: navigation, search

Relabel the file system:

touch /.autorelabel
reboot

Update security policy for a directory:

semanage fcontext -a -f "" -t httpd_sys_content_t '/www(/.*)?'
restorecon -RFvv /www

You can also temporarily change context using the chcon command.

chcon --reference=/root/ -R /www