Muthukumaran Saravanan
2006-Feb-02 02:12 UTC
[Samba] how to set share folder for every user ?
Dear Member, Thanks for your help. I have some problem in user folder maping, help me. My Smb share is [netf] path = /netf/user here i have folder for all the users right now i have 4 users for all the 4 users i have 4 folders this is their home folder while creating linux user i have specfied this path. i have 1 more folder named scan which is to be shared by all the users. 1) canny 2) willy 3) harris 4) magda 5) scan is it possible to set in such a way that automatically the scan folder should be mapped to f:\ , their home directory in g:\ depends on user. example for canny f:\ /netf/user/scan g:\ /netf/user/canny if another user login example magda for her it should be like this f:\ /netf/user/scan g:\ /netf/user/magda this should be assigned automatically, all the clinet machines are windows (some are win xp, some are win 98). User can go to any computer and login then automatically their f: and g: should get assigned. Can it be done using samba?. Should we have seperate batch file under netlogon folder for every user. Pls help me. Waiting for the tips Saravanan. -- M.Saravanan CCAT LTD, 4204 Hong Kong Plaza, 188,Connaught Road West,Hong Kong. Phone : 2851 6318. Mobile: 6100 0856 email: saravanan@ccatgroup.com
This isn't a samba issue, what you're trying to accomplish is to mount the shares automatically into the right place. You can either do this graphically using the Windows-GUI, or from the command line. See the help about the "net use" command. An example would be: mount f: \\<server>\scan /user <username> /persistent /persistent will reconnected to the share after a reboot. This would require that you set up the mounts on all workstations. The alternative is to setup a logon script that contains commands such as the one above (without the /persistent because the logon script is executed every time someone logs on). FYI: There is a "special" share called HOMES available, if you set this up. It is mapped to the unix users home directory automatically. A proper netlogon.bat script for you would be: net use f: \\server\scan net use g: \\server\homes See the Samba manual of how to set up a netlogon-script (it will require another share) and more information about users home directories (smb.conf.example is a nice place to start with).