[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: struck with ldap_add: No such object (32)



At 11:07 PM 12/20/2005, Sajag Arora wrote:
>Hi all
>I am a newbie trying to setup a ldap server
>$ldapadd -x -D "cn=Manager,dc=example,dc=com" -W -f
>/etc/openldap/example.com.ldif
>Enter LDAP Password:
>adding new entry "dc=example,dc=com"

As no errors were indicated for this entry, you can
assume <dc=example,dc=com> was added.

>ldapadd: no attributes to change or add (entry="ou=People,
>dc=example,dc=com")

The addition of the entry <ou=People,dc=example,dc=com>
failed as the LDIF didn't provide any attributes.  Likely
your LDIF input file is malformed.


>then i tried again same
>$ldapadd -x -D "cn=Manager,dc=example,dc=com" -W -f
>/etc/openldap/example.com.ldif
>Enter LDAP Password:
>adding new entry "dc=example,dc=com"
>ldap_add: Already exists (68)

This indicates that the previous add of <dc=example,dc=com>
was in fact successful.  But because of this result, additional
LDIF records are not examined.  Hence no repeat of the
above "no attributes to change or add" error.

> so i went on with importing root.ldif
>
>$ldapadd -x -D "cn=Manager,dc=example,dc=com" -W -f /etc/openldap/root.ldif
>Enter LDAP Password:
>adding new entry "uid=root,ou=People,dc=example,dc=com"
>ldap_add: No such object (32)
>        matched DN: dc=example,dc=com
>
>this doesnt make sense to me

Well, no such object indicates that the parent object
<ou=People,dc=example,dc=com> doesn't exist in the directory.
The matched DN indicates that it was only able to go down
as far as <dc=example,dc=com>.

You need to properly add <ou=People,dc=example,dc=com>.

Kurt