in reply to Ldap Search Hangs.

Most of the time I have seem this type of problem has been for one of two reasons:

1. Running searches against an un-indexed field
2. Database indexes have become corrupted

In the case of #1, I would make sure you are not searching on any fields that are not indexed. This will be very slow every time.

In the case of #2, there are a number of commands you can run to re-index the database. For this, I would take a look at the OpenLDAP documentation for more infomration on slapadd, slapcat, and slapindex.

Either alone or together, both conditions will allow for extremely slow searches. However, if both are resolved, they should be as fast as ever.

One last note: a final solution could be to completely re-build the database from scratch, using a backup of the LDAP data. This method is usually never preferred, however it's sometimes the only way to gain all the integrity of the database back.

Good Luck!

---hA||ta----
print map{$_.' '}grep{/\w+/}@{[reverse(qw{Perl Code})]} or die while ( 'trying' );