Dear LinuxQuestions.org,
As part of my learning process, I've been thinking about experimenting with using fstab-mounted network shares as home directories for users. For example, let's say I have a user `hsimpson` on a CentOS 8 system. Instead of using local `/home/hsimpson` as that user's home directory, I add this line to my `/etc/fstab` file:
Code:
\\remote\share /home/hsimpson cifs user,uid=123,rw,suid,username=foo,password=bar 0 0
Where `uid=123` is user `hsimpson`'s UID in the local system. (I know I can additionally use a credentials file instead of putting the remote username and password in fstab) Is this all that's needed to make the home directory on a remote share?
If I want to do this, what should I do when first creating the user `hsimpson` with `useradd`? How do I correctly specify this home directory? Any gotchas? Do I set up fstab first,
then create the user while specifying the fstab mountpoint as the home directory?
Also, would this incur permissions (or even SELinux?!?!?!) problems for `hsimpson`?
Thank you!