[Samba] Automatically created home only with ADUC?
Rowland Penny
rpenny at samba.org
Wed Dec 3 14:15:31 UTC 2025
On Wed, 3 Dec 2025 14:34:41 +0100
Marco Gaiarin via samba <samba at lists.samba.org> wrote:
>
> We are setting up domain members in a (MS) DC forest. We have setup
> 'Users' share for homes, following:
>
> https://wiki.samba.org/index.php/Windows_User_Home_Folders
>
> and all works as expected using ADUC; in particular, if i add
> HomeDirectory and HomeDrive property from ADUC, home folder get
> created with correct permission.
>
>
> But if i use powershell scripts, eg:
>
> Set-ADUser -Identity SamAccountName -HomeDirectory
> \\fileserver\users\utente -HomeDrive P:
>
> home get not created. we are missing something, or effectively only
> ADUC have the ability to create home?
Yes, you missed this from the wiki page you linked to:
If you are not using Active Directory Users and Computers, you must
create the folder manually and set the correct permissions.
You can manually create the users directory, or you can use a 'root
preexec' script to do it when the user first connects, much the same as
the way PAM mkhomedir works.
Rowland
More information about the samba
mailing list