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

Re: ldapadd help!

     The distinguished name "dn: cn=Manager,dc=prism,dc=fr" was
successfully added when you ran ldapadd the first time and had your problem
with the "prism" dn.  However, you still have the "Manager" dn listed in
your example ldif file.  So, ldapadd tries to add "Manager", sees that
there's already a "Manager" in the directory, and throws up the error
message.  It's kind of a pain, but ldapadd will bruteforce try to add
entries by treating them as if they are all new.  So, if you have to remove
the entries from your ldif that were successfully added leaving only those
new ones to add.  Easiest way is to cut and paste them into a new ldif and
then ldapadd that.  That way you still have all your entries in case you
want to rebuild the db at a later time.  (very likely considering how early
in development you seem to be).  Just remember, you can only use the
default ldapadd behavior to add entries not already in the directory.  Hope
it helps.

Jason McGlamary

Associate Application Specialist
Division of Nursing - Nursing Informatics
Washington Hospital Center

                    Octavio Ramirez Rojas                                                                                             
                    <Octavio.Ramirez%prism.uvsq.fr@interne       To:     Jason.McGlamary@Medstar.net                                  
                    t.mhg.edu>                                   cc:                                                                  
                                                                 Subject:     Re: ldapadd help!                                       
                    07/30/2003 11:31 AM                                                                                               

Ok, I modified example.ldif
dn: dc=prism,dc=fr
dc: prism
objectclass: dcObject
objectclass: organization
o: Prism Laboratoire

dn: cn=Manager,dc=prism,dc=fr
objectclass: organizationalRole
cn: Manager

and I have this error:

[root@azteca openldap]# ldapadd -x -D "cn=Manager,dc=prism,dc=fr" -W -f
Enter LDAP Password:
adding new entry "dc=prism,dc=fr"
ldapadd: update failed: dc=prism,dc=fr
ldap_add: Already exists (68)


Any idea?

Le mer 30/07/2003 à 17:07, Jason.McGlamary@Medstar.net a écrit :
> Octavio,
>      You should examine the required fields for the object classes you
> using.  Your error message indicates that by specifying "dn:
> " as objectclass "dcObject", you must specify the attribute "dc:" in your
> ldif definition.  Therefore, add the following to your entry for "dn:
> dc=prism,dc=fr" ......"dc: prism".  That should take care of it.  For a
> description of object classes and their required attributes check out
> http://ldap.akbkhome.com.  Hope that helps
> Jason McGlamary