Windows Drive Map Script

I’ve been tasked with setting up a Suse Enterprise Server 11 for a file server. I have it working fine using Windows AD for user logons. The two are talking with no problem. However I must have missed something in my two week forum/knowledge base crash course because I can’t get the user’s folders to be created when they first logon avoiding having to create folders manually for over 300 users. Someone please tell me there is a way to script this. Below is the smb.conf. Thanks to everyone in advance. todd

smb.conf is the main Samba configuration file. You find a full commented

version at /usr/share/doc/packages/samba/examples/smb.conf.SUSE if the

samba-doc package is installed.

Date: 2009-02-23

[global]
workgroup = Domain
netbios name = Domain-File
realm = Domain.LOCAL
name resolve order = host lmhosts wins bcast
local master = yes
os level = 33
printing = cups
printcap name = cups
printcap cache time = 750
cups options = raw
map to guest = Bad User
include = /etc/samba/dhcp.conf
logon path = \%L\profiles.msprofile
logon home = \%L%U.9xprofile
logon drive = P:
password server = Server-dc2.Domain.local
usershare allow guests = Yes
usershare max shares = 100
usershare owner only = False
usershare path = /var/lib/samba/usershares
server string = “Linux”
security = ADS
encrypt passwords = yes
preferred master = no
template shell = /bin/false
template homedir = /home/%D/%U
idmap uid = 10000-20000
idmap gid = 10000-20000
enhanced browsing = no
winbind enum users = yes
winbind enum groups = yes
winbind use default domain = yes
winbind refresh tickets = yes
wins support = No
wins server = Server-dc1
passdb backend = smbpasswd
[homes]
comment = Home Directories
valid users = %S, %D%w%S
browseable = No
read only = No
inherit acls = Yes
[profiles]
comment = Network Profiles Service
path = %H
read only = No
store dos attributes = Yes
create mask = 0600
directory mask = 0700
[users]
comment = All users
path = /home
read only = No
inherit acls = Yes
veto files = /aquota.user/groups/shares/
[groups]
comment = All groups
path = /home/groups
read only = No
inherit acls = Yes
[printers]
comment = All Printers
path = /var/tmp
printable = Yes
create mask = 0600
browseable = No
[print$]
comment = Printer Drivers
path = /var/lib/samba/drivers
write list = @ntadmin root
force group = ntadmin
create mask = 0664
directory mask = 0775