<br><div class="gmail_quote">2009/7/9 hqm8512 <span dir="ltr"><<a href="mailto:hqm8512@126.com">hqm8512@126.com</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>hello ,<br>we're using LDAP for user authentication<br>
<br>
I'm looking for a mechanism to automatically create a users home directory<br>
when he logs in for the first time <br>
Thanks,<br></div></blockquote></div><br>The autodir package will do precisely that.  It's easy to setup too:<br>
<span><br>
 </span>yum -y install autodir<br>
<span> </span>mkdir /u<br>
<span>    </span><br>
<span> </span>Edit /etc/sysconfig/auto<br>
<span>  </span><span>    </span>AUTOHOME_HOME=/home/ldapusers<br>
<span>  </span><span>    </span>AUTOHOME_OPTIONS="realpath=/u,level=2,skel=/etc/skel,mode=0700"home<br>
<span>    </span><br>
<span>    </span>service autohome start<br>