Hi,
round two, fight :)
Yes, I use samba as a PDC.
I use openldap to authenticate users in samba, so, I can do this
smb.conf
[home]
path = /media/usb_drive/home/%S
???
Main Topics
Browse All TopicsHi,
It is possible change home directories path to a usb drive ?
for example:
when I create a new user in samba, instead of the user profile is stored in /home/user, can be stored in /USBDevice/home.
How I make this ?
change home path in smb.conf ?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
You didn't set the correct setting.... here's a snippet from my smb.conf file:
domain logons = Yes
domain master = Yes
preferred master = Yes
logon script = logon.bat
logon path = \\%L\Profiles\%U
logon drive = U:
logon home = \\%L\%U
So you see, it's not "home =" but "logon home = "
Try again!
Dan
IT4SOHO
My bad.... the section you may want to change is in the [homes]
And that is the key -- it's [homes] not [home] (the "special" share name).
Then, within that [homes] section, you can place the path= variable... so:
[homes]
comment=Personnal Folder
browseable=No
writeable=Yes
path = /media/usb_drive/home/%S
I hope this one does it!
Dan
IT4SOHO
If you're talking about when you run useradd in Linux, then what you should be adjusting is the useradd defaults in Linux.
The "useradd -D" command is how you change defaults, and the "-d" changes the default folder.... together, that makes:
useradd -D -d /media/usb_drive/home/
The system will then remember where user home folders should default to, and when a new user is created the folder will be created at /media/usb_drive/home/<use
Woe be it unto you should that USB drive get removed.... you have been warned... <grin>
I hope this is what you needed....
Dan
IT4SOHO
Business Accounts
Answer for Membership
by: it4sohoPosted on 2009-10-08 at 15:04:59ID: 25530682
You can specify the user's home path in the smb.conf (assuming you are using samba as a PDC and the user is logging into a domain computer with a domain account)... BUT
g/samba/do cs/man/man pages-3/ sm b.conf.5.h tml), and that allows you to setup each user's home folder separate from their Linux home folder (or the same -- your choice).
- if the USB device is to be inserted into the samba server, it will have to be shared & the URL (e.g.: \\server\USB) is what will be specified as the home directory
- if the USB decice is to be inserted into the LOCAL machine, it will have to have a "static" drive letter. Windows doesn't have a way to access "USB-DRIVE" -- only drive letters. And if the user "roams" to a system that, for example, has an extra DVD RW installed, so the USB drive gets a different drive letter when inserted, then your scheme will break.
The home path for users is set in the global section of smb.conf. A sample might be:
logon home = \\%L\%U
Where %L is expanded to be the NetBIOS name of the samba server and %U is the session username (the username used to create the $IPC connection).
NORMALLY those home folders are actually shared through the [homes] facility (see http://http://www.samba.or
This should get you started! Write back with the next round of questions! (I know there will be another round!)
Dan
IT4SOHO