[Samba] pam_mkhomedir - was: Re: Samba 4 AD [homes] Share

Rowland Penny rowlandpenny at googlemail.com
Thu Jan 16 12:04:33 MST 2014


On 16/01/14 18:34, Márcio Merlone wrote:
> Em 16-01-2014 16:20, Rowland Penny escreveu:
>> With this, (and pam_mkhomedir in common-session) when a user logs 
>> into a linux machine, their home directory is created for them at 
>> /home/username.
>>> In fact, I sent another message to the list regarding this. When 
>>> logging in from a windows machine, the user home is created, but not 
>>> honoring /etc/skel as if the user logged from ssh, for example.
>>
>> You have a problem here, the problem being that you are confusing 
>> windows users and linux users.
> Am I? With SSSD or Winbind or pam_ldap all windows users are also 
> linux users, provided they have unix attributes.
>
>> When a windows user logs in (and you are using roaming profiles) it 
>> will use whatever path you put in the 'profilePath' attribute in the 
>> users AD. A linux user uses different attributes, ' 
>> unixHomeDirectory' & 'loginShell', you should not mix these 
>> attributes, but you can connect to the users linux home directory 
>> from a windows machine.
> I was expecting that when a user logs in, no matter from windows or 
> ssh, its homedir were created according to 'pam_mkhomedir.so 
> skel=/etc/skel/ umask=0027', which does happen only on ssh, not when 
> coming from windows.
>
>
> -- 
> *Marcio Merlone*
> TI - Administrador de redes
>
> *A1 Engenharia - Unidade Corporativa*
> Fone: 	+55 41 3616-3797
> Cel: 	+55 41 9689-0036
>
> http://www.a1.ind.br/ <http://www.a1.ind.br>
If you using samba 4 as an AD server, then a windows user can also be a 
linux user and vice-versa, but they have to be set up correctly, i.e. 
they need both the windows & the linux attributes. Having said that, 
when a user logins into a windows machine, they download their profile 
from the server, they do not login to the AD server. The windows user 
can login to the AD server and their home directory will be created, 
just as if they login via ssh.

Rowland


More information about the samba mailing list