LDAP я не использую. содержимое файла smb.conf такое:
[global]
workgroup = DESIGN.ORG
netbios name = PDC-DESIGN.ORG
server string = SAMBA PDC for DESIGN.ORG
security = ADS
encrypt passwords = yes
hosts allow = 192.168.0. 127.0.0.
syslog = 0
log level = 10 passdb:10 auth:10 winbind:10
log file = /var/log/samba/log.%m
max log size = 100
socket options = TCP_NODELAY
interfaces = 192.168.0.0/24
local master = yes
os level = 85
domain master = yes
preferred master = yes
domain logons = yes
idmap uid = 5000-9999
idmap gid = 5000-9999
mangling method = hash2
display charset = koi8-r
unix charset = koi8-r
dos charset = cp866
logon script = logon.bat
logon path =
logon home =
template homedir =
wins support = yes
dns proxy = no
# These scripts are used on a domain controller or stand-alone
# machine to add or delete corresponding unix accounts
add user script = /usr/local/etc/samba/adduserscript.sh "%u"
add group script = /usr/sbin/pw groupadd "%g"
add user to group script = /usr/local/etc/samba/addusertogroupscript.sh "%g" "%u"
# For add account
add machine script = /usr/local/etc/samba/addmachinescript.sh
# Script to prevent simple passwords (12345 etc)
# The password is transferred to an input of the script
check password script = /usr/local/etc/samba/checkpassword.sh
delete user script = /usr/sbin/pw userdel "%u" -r
delete user from group script = /usr/local/etc/samba/deleteuserfromgroupscript.sh "%g" "%u"
delete group script = /usr/sbin/pw groupdel "%g"
rename user script = /usr/local/etc/samba/renameuserscript.sh "%uold" "unew"
shutdown script = /usr/local/etc/samba/shutdownscript.sh
# Setup pramary group for user
set primary group script = /usr/sbin/pw usermod "%u" -g "%g"
message command = /bin/mail -s 'message from %f on %m' root < %s; rm %s
[homes]
comment = Home directories
browseable = no
writable = yes
public = no
valid users = %S
[netlogon]
comment = Network logon service
path = /home/samba/netlogon
guest ok = yes
writable = no
browseable = no
[profiles]
comment = Roaming profile share
path = /home/samba/profiles
read only = no
browseable = no
guest ok = yes
writeable = yes
create mask = 0600
directory mask =0700
profile acls = yes
; force user =%U
; valid users = %U @"Domain admins"
[public]
comment = Common share
path = /home/samba/share/pub
valid users = @"Domain admins", @"Domain users"
public = yes
browseable = yes
guest ok = yes
read only = no
writable = yes
directory mask = 0777
create mask = 0765
[myshare]
comment = Share user
path = /home/samba/share/shareuser
valid users = shareuser
public = no
guest ok = no
read only = no
writable = yes
directory mask = 0777
create mask = 0765