On 7/22/21 10:46 AM, Lars Kellogg-Stedman wrote:
On Thu, Jul 22, 2021 at 10:33:52AM -0400, Lars Kellogg-Stedman
wrote:
> any special selinux context on the directory I'm trying to export; I
> simply ran `mkdir /data`, which results in:
>
> [root@nfs1 data]# ls -lZd /data
> drwxr-xr-x. 2 root root system_u:object_r:unlabeled_t:s0 82 Jul 22 14:15 /data
I think I've found the problem.
The /data directory is the mounting of an XFS filesystem. While the
label on the directory looks like this before mounting the filesystem:
[root@nfs1 ~]# ls -lZd /data
drwxr-xr-x. 2 root root system_u:object_r:default_t:s0 6 Jul 22 14:43 /data
It is type unlabeled_t after mounting a freshly created filesystem.
The solution appears to be:
restorecon -R /data
After which things appear to work correctly.
Good to know. It didn't occur to me that it could be unlabeled.
Daniel