How to automount NIS account's home dir to a different location?
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How to automount NIS account's home dir to a different location?
Hi,
### problem:
Quote:
user account on NIS server: user
Home dir as set in /etc/passwd: /home/user
proposed mountpoint for NIS client home dir for 'user': /shared/home/user
auto mounting to /home/user works fine
BUT if i want to automount to different location; it still looks for /home/user directory to mount to. So I get an error and i get directed to the '/' dir.
Is there someway for me to edit the passwd file that is being exported by the NIS server? because if I change the local passwd of the user in the NIS server then he wont be able to see his home dir when logging in locally. (although this does seem to be a good idea; since he wont need to login directly into the NIS server....)
Distribution: Debian /Jessie/Stretch/Sid, Linux Mint DE
Posts: 5,195
Rep:
On the box which is the NIS master server you can modify the user settings. If you use adduser you can change the home directory. Man adduser is more accurate than I am, so check that.
NIS intercepts adduser calls so the YP databases are updated whenever you run adduser. If that doesn't work, run make in /var/lib/yp. You might also have to restart NIS on the server.
You must login again on the client for the changes to propgate.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.