Manually created homedirs for ldap - cannot log on through X
Hey guys.
I've just started experimenting with LDAP through classes I'm taking. And I came across a problem that I seem to not be able to solve. Here is the deal. At first, I created few user account, local ones, on the computer that's supposed to be ldap server. After adding these users, I used migration scripts in Fedora 8 to take out the necessary stuff needed for ldap to function normally with home directories (migrated /etc/passwd,shadow and group). After that, I removed the physical accounts but left the home dirs. After this, I was able to access these accounts by logging in from another computer that was set up as ldap client with autofs/autohome setup. Everything worked flawlessly just as I wanted it. Then I figured I would create an additional account, manually, just to see how it works. I used the same logic, made sure that the UID/GID didn't conflict with anything existing on the server etc. Here is how I created an ldif file for a new user (I used the exact same syntax just like one created by migrating scripts, and of course changed necessary stuff to match this one particular account I was about to create). Code:
dn: uid=newaccount,ou=People,dc=my-domain,dc=com Code:
dn: cn=newaccount,ou=Group,dc=my-domain,dc=com Then, since this is manual creation, I created the home dir according to path above, I made sure to have changed ownership to uid/gid 504 as above. Then, when I tried to logon from the ldap client, through ssh it went with no problems. Home dir seem to have been accepted too - I could create files and I could clearly see that I was in /home/newaccount (pwd command). However, then I tried to logon through X and it threw me out. Couldn't see any info in the log files (/var/log/messages). However, after inspecting the actual home dir, I found some very strange stuff in the .xsession-errors file which was generated by the unsuccessful X-login: Code:
Can't create dir /nohome/Desktop After that, I redone the manual home-dir creation and I even copied the content from /etc/skel figuring that was the cause of the problems (no default maps present) - still the problem persists. Very frustrating but hopefully some of you gurus will help me out. Thanks in advance! M. |
You may have the wrong security context (SELinux)
Have a look at ls -lZ /home and see if the context for the directory you created is different from those created previously. Here's an example of what you may see Code:
drwxrwxr-x root users root:object_r:user_home_dir_t common If so, see man restorecon and man chcon |
Quote:
Hi there. Thanks for the suggestion. My SELinux is, however, disabled, so that's not the problem. Must be something else. Could it be something related to Xauthority? Hmm... |
When you copied over the files from /etc/skel, did you change the owner and permissions?
|
All times are GMT -5. The time now is 11:14 AM. |