[Samba] Use Samba with ACL for read Active Directory and set Permissions via it.

jacek burghardt jaceksburghardt at gmail.com
Fri Dec 26 16:11:58 MST 2014


I use this script to create folders for users
#!/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
 [global]
        template shell = /bin/bash
        template homedir = /data/homes/%D/%U
        root preexec = /usr/bin/mkhomedir.sh %D %U


SO what happens when you chown jason /home/local/jasondomain/jason/test
is jason also listed in /etc/password there could be a conflict


More information about the samba mailing list