Description of problem: The underlying directories where file systems are mounted do not get relabeled when an automatic fs relabeling is forced. This is because the relabeling happens when file systems are already mounted. Mislabeled mount points can happen after / is restored from backup. Version-Release number of selected component (if applicable): initscripts-8.45.7-1 How reproducible: 100% Steps to Reproduce: 1. Misslabel a mount point for instance /var 2. touch autorelabel, reboot Actual results: The mount point doesn't get relabeled. In case of /var this leads to errors in the logs at every reboot after the relabeling: tobsbox kernel: audit(1166612710.404:49): avc: denied { search } for pid=1196 comm="rhgb" name="var" dev=md0 ino=863265 scontext=system_u:system_r:rhgb_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=dir Expected results: The underlying mount points get relabeled. Maybe before mounting all file systems in rc.sysinit, all mount points in /etc/fstab should be relabeled. Unmounting the fs and running restorecon manually on the mount points gets rid of the errors at boot. Additional info: Bug 217286 is a special case of this, regarding the /etc/rhgb/temp mount point. That case is more complicated than /var, /tmp etc given how early rhgb mounts stuff there. Tobias
Makes sense.
*** Bug 217286 has been marked as a duplicate of this bug. ***
Created attachment 152724 [details] patch for this Here's what will be in 8.52-1.