[Date Prev][Date Next]
Re: Problems deleting entries
At 04:46 PM 9/2/99 -0500, Amy Tebbe wrote:
>1. What would cause an ldap_delete: Operations error?
slapd may return a operations error upon delete due to a
variety of circumstances.
could not find parent entry
id2children index removal failure
dn2id index removal failure
entry cache/disk removal failure
The server will log the specific cause if appropriate
logging (-d 5) is enabled.
>I'm trying to delete some entries that I put in awhile back when I
>was playing with ldap. Now I can't delete them, with either
>gq or ldapdelete. I can delete other entries, though, so I don't
>think it's a bind problem and the error does not indicate a bind
>problem. The only think I can think of is that those entries were
>created improperly or are defined improperly. Is there any way
>to force them to be deleted?
It's likely that your indices are corrupt. These can be rebuild
individually or all together using ldbmcat and ldif2* tools.
>Here's what I've tried:
>[root@king tmp]# ldapdelete -v -D cn=root,dc=real-time,dc=com -w secret
>"cn=Amy Tanner, ou=staff, dc=real-time,dc=com"
>deleting entry "cn=Amy Tanner, ou=staff, dc=real-time,dc=com"
>ldap_delete: Operations error
>2. What's the easiest way to wipe the entire ldap database so I
>can start with a fresh, blank copy?
After ensuring you have appropriate system backups:
1) stop slapd
2) use ldbmcat(8) to generate LDIF file from your id2entry
3) remove all files from your database directory
4) use ldif2ldbm(8) to rebuild database
5) start slapd
If you are unsure the consistency of your data, you may want to skip
step 4 (ie: start slapd without a preexisting database) and then use
ldapadd(1) to add your entries.