« The Vulgarity of Anonymity, the Death of Empathy | Eeepc goofed up volume control when playing video » |
Tired of ssh'ing into a machine that has ldap authentication but doesn't have a home directory for you? Adduser or useradd doesn't work when user already exists in the Ldap directory. You can manually create the directory, copy the files in from /etc/skel and change the permissions but there is an easier fix.
First verify that you have pam_mkhomedir.so in /lib/security Then all you need to do is to add the following line to /etc/pam.d/sshd and systems that don't have a home directory for your login name will have one created the first time you connect via ssh.
session required pam_mkhomedir.so skel=/etc/skel/ umask=0022
That's it, there is no more.