[Samba] profiles and home directories

Greg Andrews andrews at rgt.com.au
Tue Nov 30 04:03:03 GMT 2004


Howdy All,

I have read with interest the problems that some people have with profiles
and XP ( service pack 2 included ) in getting them to work.
I, however, have not had any such trauma's ( thank goodness) and the
smb.conf file listed below works a treat.
The problem I have is people using profiles over several vpn connections (
just to slow ).
So now I am in the situation of wanting to turn off profiles. Ha Ha I hear
people say, thats simple, just set  logon home = and logon path = and
leave them blank and bingo no profiles. Absolutely correct.
There is however one small problem. When I do this I also lose the users
home directories.:(
I have read the appropriate section in the HOW-TO book and it says that
using [homes] section in the conf file with facilitate the use of
net use h: /home in the logon script. Alas no.
I have either stuffed something else up or samba is not playing the game
according to the book of words ( many thanks to John Terpstra  and his
efforts). I fear its the former.
Basically I need to be able to run only local profiles ( yes I know there
are registry hacks to do this, but server level commands are so much
neater ) but still have the users run login scripts .

I have listed below my smb.conf file ( the one that works with profiles )
and also my very simple logon.bat file ( which also runs well ) for any
gurus out there who may be able to help.

If I set the logon home = and logon path =   then the logon.bat file works
for all of the mappings except the home directory mapping.!!!
It has to be simple but I just cant see  it.

Any and all help appreciated

Greg Andrews

ps testparm says everything is OK and there is an I cant find the path
error when the logon script is run for the home directories.


[global]
        log file = /var/log/samba/log.%m
        load printers = no
        name resolve order = wins bcast lmhosts host
        admin users = @admingrp
        socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
        obey pam restrictions = Yes
        lm announce = True
        domain master = True
        username map = /etc/samba/user.map
        encrypt passwords = yes
        passwd program = /usr/bin/passwd %u
        wins support = true
        time server = Yes
        dns proxy = No
        netbios name = SAMBASERVER
        server string = sambaserver
        logon script = logon.bat
        unix password sync = yes
        workgroup = PINARC
        os level = 255
        security = user
        preferred master = yes
        max log size = 50
        domain logons = yes
        logon drive = h:
        logon home =\\%N\%U
        logon path = \\%L\profiles\%u\%m
        add user script = /usr/sbin/useradd -d /dev/null -g 400 -s
/bin/false -M /%u

[profiles]
        comment = Profiles Directory
        path = /SYS/profiles
        read only = No
        create mask = 0775
        directory mask = 0775
        profile acls = Yes

[netlogon]
        comment = For Administration Use
        path = /etc/samba/netlogon
        valid users = %U
        write list = @admingrp
        read only = no
        create mask = 0644

[homes]
        comment = %U home directory
        path = /SYS/home/%U
        valid users = %S
        read only = No
        create mask = 0600
        directory mask = 0700
        browseable = No
        locking = no

[open]
        comment = Pinarc Readable Share
        path = /SYS/world/open
        read only = No
        create mask = 0664
        directory mask = 0775
        valid users = @ebody





echo Mapping Home directories
net use h: /home
net use o: \\SAMBASERVER\open
net use l: \\SAMBASERVER\lukeman
net use i: \\SAMBASERVER\inter
net use m: \\SAMBASERVER\mad



-- 
Greg Andrews
System Manager
RGTechnologies Pty Ltd
606 Skipton Street
Ballarat 3350
613 53363603
0417 511 731
andrews at rgt.com.au


More information about the samba mailing list