[Samba] Samba PDC adding new user, profile dir is not created
Wasil
sub_wasil at mail.ru
Wed Mar 16 04:33:01 MDT 2011
Hi
You must have something like this:
in smb.conf^
[profiles]
.....
root preexec = /usr/local/bin/mkprofile.sh %u %g
....
mkprofile.sh:
#!/bin/sh
PROFILE=/data2/profiles/$1
if [ ! -e $PROFILE ]; then
mkdir -pm700 $PROFILE
chown $1:$2 $PROFILE
fi
Wed, 16 Mar 2011 11:09:59 +0100 письмо от "J. Echter" <j.echter at elektro-mayer-echter.de>:
> Hi,
>
> i have a Samba PDC (no LDAP) and added add user script to my config.
>
> I can create the user with no problems, login is possible but the
> /home/samba/profile/user dir is not created.
>
> Any hints on that?
>
> script commands i added:
>
> add user script = /usr/sbin/useradd -m '%u' -g ntusers -G ntusers -s
> /bin/false
> delete user script = /usr/sbin/userdel -r '%u'
> add group script = /usr/sbin/groupadd '%g'
> delete group script = /usr/sbin/groupdel '%g'
> add user to group script = /usr/sbin/usermod -G '%g' '%u'
> add machine script = /usr/sbin/useradd -s /bin/false -d /var/lib/nobody
> '%u' -g machines
>
>
> this is running on Ubuntu 10.04-LTS server
>
>
> greetings
>
> Juergen.
> --
> To unsubscribe from this list go to the following URL and read the
> instructions: https://lists.samba.org/mailman/options/samba
More information about the samba
mailing list