![]() |
Unable to chown a directory to a user on LDAP Server
Hi,
I am using RHEL5.1 distribution. Openldap-server version is openldap-servers-2.3.27-8. I have detailed only the steps which are confusing me/are not in accordance to the link-http://www.linuxhomenetworking.com/w...DAP_and_RADIUS Now; as per the link ...I ran the command 1. Code:
# cp -rv * /usr/share/openldap/migration/2. Quote:
Hence; I issued Code:
#cp /etc/openldap/DB_CONFIG.example /var/lib/ldap/example.com/DB_CONFIGCode:
#/usr/share/openldap/migration/migrate_all_offline.sh > /root/migrop 2> /root/migrerr--------------------------------------------------------------------- Creating naming context entries...--------------------------------------------------------------------- The contents of /root/migrerr {This file contains errors of the script.}are: ------------------------------------------------------------------------------------- slapadd: line 5: database (dc=example,dc=com) not configured to hold "dc=padl,dc=com" slapadd: line 5: database (dc=example,dc=com) not configured to hold "dc=padl,dc=com" ------------------------------------------------------------------------------------- On both server & client machine; 4. Output of the command-> Code:
ldapsearch -x -b 'dc=example,dc=com' '(objectclass=*)'# extended LDIFOn both server & client; 5. Code:
But; still the issuance of the command Code:
# chown -R ldapuser:users /home/ldapuser/Code:
chown: `ldapuser:users`:invalid user |
Do you actually have users in your ldap directory? To me, it looks like you don't have any... Furthermore have you set up /etc/ldap.conf, /etc/openldap/ldap.conf and /etc/nsswitch.conf?
What does 'getent passwd' return? Does it contain the users, if they exist, in the ldap directory? |
Contents of ldap.conf and nsswitch.conf
My LDAP server's IP address is 192.168.0.7.
I have not yet implemented Secure LDAP. Quote:
Quote:
Following are their contents-> /etc/ldap.conf Code:
base dc=example,dc=comCode:
BASE dc=example,dc=comCode:
passwd: files ldapQuote:
Quote:
|
The migration tool probably creates an ldif file or maybe you have to add the ldif filename to CLI command (not really sure about that, been to long ago that I have done this). This ldif you have to add to your ldap directory with the slapadd command. Don't forget to stop the ldap service when you are going to do this.
|
Forgot to mention this in my previous post, but ldapsearch is the correct client tool to list the contents of your ldap directory.
This is some example output when I run ldapsearch on my systems: Code:
[user@localhost ~]$ ldapsearch -x -ZZ '(cn=admin)' |
I just saw that you already used slapadd... The 2 errors you got mean that you didn't set the correct domain in your migration tool configuration.
You are trying to add dc=padl,dc=com attributes to a directory that is configured to use dc=example,dc=com. This is not possible and will fail. |
Reason for Late Reply.
As BlueIce correctly pointed out; the settings file had to be changed. But; sometimes it worked & sometimes it did not. I am still perplexed about this Yes!!! It works/No!!! it is not working. Still trying to figure out. But; I will mark this thread as solved.
|
| All times are GMT -5. The time now is 05:33 PM. |