[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: Modifying the DN
Quoting Susanth_TS@sifycorp.com:
> I have a requirement of changing the DN of particular entry. For example , would
> like to move the uid: test from ou=south to ou=north
>
> "uid=test, ou=south, o=global" to "uid=test, ou=north, o=global"
>
> Two options
>
> 1. ldap_rename() : Openldap does not support this. Is there any configuration
> that has to be done to make openldap suport this facility ?.
man ldapmodrdn
Note thought, that it can't handle the rename of a DN if it has childrens...
This will be implemented in OpenLDAP v2.1 (if I'm not remembering wrongly).
> 2 Delete ( ldap_delete() ) and recreate the uid in a different ou : Is this a
> correct sollution ???
That's what I do.
I extract the DN (and all it's childrens) with the root DN (in reality, I don't
HAVE a root dn any longer, I use kerberos and SASL) and then modify this LDIF
and then add it back. When I have verified that it's correct, I delete the original
DN(s).
> doubt if the berkely DB would get corrupted if there are
> too many deletes. Do i have to check for something or synchronise the db after
> deleting the entry to make sure that the databse is not corrupted ?
Not that I'm aware of. Slapd takes care of all this...
> Please suggest if there is someother way of solving this ?
Currently there is no other way. You CAN always wait for OpenLDAP 2.1 to
be stable and/or have this implemented and then help test it, making it
enter 'stable' mode quicker :)