[CentOS] nfs mounted /home and selinux

Marc Wiatrowski mwia at iglass.net
Thu Oct 30 21:00:35 UTC 2008

I'm trying to set the context on an nfs mounted /home.  I believe
exactly like in Redhat's Deployment Guide at


On my system running CentOS 5.2:

$ ls -alZ /home
drwxr-xr-x  root root system_u:object_r:home_root_t    .
drwxr-xr-x  root root system_u:object_r:root_t         ..

$ mount -t nfs -o context=user_u:object_r:user_home_dir_t \
     server001a:/vol/vol01/home /home

$ ls -alZ /home
drwxrwxr-x  root         root    system_u:object_r:nfs_t          .
drwxr-xr-x  root         root    system_u:object_r:root_t         ..
drwx------  fred         users   system_u:object_r:nfs_t          fred
drwx------  mike         users   system_u:object_r:nfs_t          mike
drwx------  alice        users   system_u:object_r:nfs_t          alice

$ mount -l
server001a:/vol01/home on /home type nfs

Shouldn't the users be set to user_u:object_r:user_home_dir_t?  I feel
like I am missing something simple...

I don't see any avc or related syslog messages and the nfs server is an
older netapp if that matters.


More information about the CentOS mailing list