[Samba] Home auto creation
Rowland Penny
rowlandpenny at googlemail.com
Mon Dec 22 02:26:25 MST 2014
On 22/12/14 00:55, jacek burghardt wrote:
> Well that is great way of doing it. I read
> https://help.ubuntu.com/community/ADWin2k8KerberosLDAP and used this script
> #!/bin/bash
>
> if [ ! -e /data/homes/$1/$2 ]; then
> /usr/bin/mkdir -p /data/homes/$1/$2
> /usr/bin/chown "$2":"Domain Users" /data/homes/$1/$2
> /usr/bin/chmod g+s /data/homes/$1/$2
> /usr/bin/chmod 770 /data/homes/$1/$2
> /usr/bin/setfacl -m g:"domain admins":rwx /data/homes/$1/$2
> /usr/bin/setfacl -m u:"$2":rwx /data/homes/$1/$2
>
> fi
> exit 0
> It works but your solution it is much easier.
Or you could just use 'pam_mkhomedir' on the Unix computer that will
hold the homedir.
Rowland
More information about the samba
mailing list