13.9.13

Samba4 autofs II

Part 1 of this post is HERE

Intro
Following on from the runaway success my last post, today, we'll add another share. This time, we'll go one stage further back; to the file server.

smb.conf 
on the file server has this:
[shared]
path = /home/shared
read only = No
inherit acls = Yes

Files
/etc/auto.master on the clients is:
/home/shared /etc/auto.shared

/etc/auto.shared is:
*   -fstype=cifs,sec=krb5,username=cifsuser,multiuser   ://altea/shared/&

And here is the ldif:

shared.ldif

dn: cn=/home/shared,CN=auto.master,CN=HH3,CN=defaultMigrationContainer30,DC=hh3,DC=site 
objectClass: top
objectClass: nisObject
cn: /home/shared
name: /home/shared
nisMapName: auto.master
nisMapEntry: auto.shared

dn: CN=auto.shared,CN=HH3,CN=defaultMigrationContainer30,DC=hh3,DC=site
objectClass: top
objectClass: nisMap
cn: auto.shared
name: auto.shared
nisMapName: auto.shared

dn: cn=*,CN=auto.shared,CN=HH3,CN=defaultMigrationContainer30,DC=hh3,DC=site
objectClass: top
objectClass: nisObject
cn: *
name: *
nisMapName: auto.shared
nisMapEntry: -fstype=cifs,sec=krb5,username=cifsuser,multiuser ://altea/shared/&

Add to the directory and that's it. No walking all over the park adjusting every single client when you make a change!