[Samba] smb.conf question. multiple /home/shares

Michael Heydon michaelh at jaswin.com.au
Mon Nov 26 23:17:23 GMT 2007


Have a look at the section of the man page regarding  the [homes] share. 
It will do all this automatically.

In it's simplest form

[homes]
read only = no

will share everyones home directory read write as \\server\username.


*Michael Heydon - IT Administrator *
michaelh at jaswin.com.au <mailto:michaelh at jaswin.com.au>


Dimitris Theoharis wrote:
> Hi
>
> This is what i want to do :
> each windows pc will have its own /home/username on this samba server.
> for example i have added 3 users so far and my .conf is like this :
> [george]
>    comment = Home
>    path = /home/george
>    #valid users = %S
>    read only = no
>    browsable = yes
> [trandism]
>    comment = Home
>    path = /home/trandism
>    read only = no
>    browsable = yes
> [xristoforos]
>    comment = Home
>    path = /home/xristoforos
>    read only = no
>    browsable = yes
>
>
> now , when each user logs in will he get a \\serverip\username on his
> explorer window?
>
> i will include here my smb.conf too . make any suggestions you want ;)
>
>
> cat /etc/samba/smb.conf
> [global]
>         log file = /var/log/samba/log.%m
>         hide unreadable = yes
>         logon drive = H:
>         hide dot files = yes
>         null passwords = no
>         hosts allow = ALL
>         netbios name = Master
>         server string = %h server (Samba, Debian)
>         logon script = \\192.168.10.198\netlogon\%U.bat
>         workgroup = OCR
>         logon path = \\192.168.10.198\%U
>         security = user
>         domain logons = yes
>         log level = 3
>         winbind cache time = 10
>
>    #passdb backend = tdbsam
>    #username map = /etc/samba/smbusers
>    #name resolve order = lmhosts bcast hosts
>    #preferred master = yes
>    #os level = 65
>
>    # Default logon
>
>
>    # Useradd scripts
>    #add user script = /usr/sbin/adduser --quiet --disabled-password
> --gecos "" %u
>    #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/usernod -G %g %u
>    #add machine script = /usr/sbin/useradd -s /bin/false/ -d /var/lib/nobody %u
>    #idmap uid = 15000-20000
>    #idmap gid = 15000-20000
>    #template shell = /bin/bash
>
>    # set the loglevel
>
>   #[public]
>    #path = /home/shares
>    #browseable = yes
>    #public = yes
>    #write list = @users
>
>
> [george]
>    comment = Home
>    path = /home/george
>    #valid users = %S
>    read only = no
>    browsable = yes
> [trandism]
>    comment = Home
>    path = /home/trandism
>    read only = no
>    browsable = yes
> [xristoforos]
>    comment = Home
>    path = /home/xristoforos
>    read only = no
>    browsable = yes
>
> [netlogon]
>    comment = Network Logon Service
>    path = /home/samba/netlogon
>    admin users = Administrator
>    valid users = %U
>    read only = no
>    guest ok = yes
>    writable = no
>    #share modes = no
>
> [profile]
>    comment = User profiles
>    path = /home/samba/profiles
>    valid users = %U
>    create mode = 0600
>    directory mode = 0700
>    writable = yes
>    browsable = no
>    guest ok = no
>
> [allusers]
>   comment = All Users
>   path = /home/shares/allusers
>   valid users = @users
>   force group = users
>   create mask = 0660
>   directory mask = 0771
>   writable = yes
>   


More information about the samba mailing list