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

Re: query reply time



It depends on the base of your search.  If the search base == database suffix,
then it will finish immediately.  Otherwise, OpenLDAP 1.2.6 and above will
actually scan every object in your database, which is probably what causes
the pause that you observe.  Another possibility is that you do not have an
index built on uid, which would also force a full scan of the database.

Randy

>     I couldn't help noticing that using ldapsearch to preform a query on a uid,
> 
> being the uid part of the dn, i.e. dn: uid=xpto, o=myorg, c=country and although
> 
> that object is unique after ldapsearch has found my entry it "freezes" for one
> 
> second or two seconds letting me think that it's still searching for other occurances in the
> 
> database. After preforming a strace of the ldapsearch line i saw that even after getting
> 
> the entry in question it still preforms a select and a read ... does that mean he goes
> 
> searching for other entries even after he finds a match that he knows(?) it is unique?
> 
>     If so, is there any way to "tell him" that he should be satisfied with that 1st match
> 
> and that "he" should end the query there?
> 
> note: response time is indeed a powerfull factor when it comes to services interacting with ldap.
> 
> Thanks in advance,
> 
> Hugo.
> 
> --
> ---------------------------------------------------------------------------
> | Hugo Monteiro                      | M_vel: +351-966 386 090            |
> | Servi_o de Inform_tica da          | Fixo : +351-212 948 300 Ext.1 0703 |
> | Faculdade de Ci_ncias e Tecnologia |                             1 5306 |
> | Universidade Nova de Lisboa        |                                    |
> | 2825-114 Monte Caparica            | Email: hmmm@fct.unl.pt             |
> ---------------------------------------------------------------------------
> 
>