I've got a couple of CentOS 7 client machines authenticating against OpenLDAP right now. The next step is to get autofs working. Which I have, but my map loads all users at once. I'd like to avoid this. Assume I have two users
user1
user2
They both have a NFS share and I want to map them using autofs.
/home -fstype=nfs,rw domain.com:/homes
Works, but I get everyone. I thought that I could use variables or wildcards to achieve this. So I attempted the following map
/home/${USER} -fstype=nfs,rw domain.com:/homes/${USER}
/home/${USER}/Music -fstype=nfs,rw domain.com:/homes/${USER}/&
But it would appear that my variables aren't liked by CentOS. I've tried
/home/${USER} -fstype=nfs,rw domain.com:/homes/${USER}
/home/$USER -fstype=nfs,rw domain.com:/homes/$USER
/home/* -fstype=nfs,rw domain.com:/homes
Could someone please tell me what I'm missing?
Thank you!
Edited for logs
Dec 8 22:22:13 workstation automount[1897]: setautomntent: lookup(sss): setautomntent: No such file or directory
Dec 8 22:22:13 workstation automount[1897]: do_mount_autofs_direct: failed to create mount directory /home/${USER}