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

Re: LDAP search question



Are the attrs list returned in both entries euqal ?

Try to use the 1.1 attrs list.

man ldapsearch:
If no attrs are listed, all user attributes are returned.  If only 1.1 is listed, no attributes will be returned.

Regards

On Mon, Jun 15, 2009 at 8:29 AM, Tihomir Culjaga <tculjaga@gmail.com> wrote:
Hello,

maybe it is a dummy question but i'd like to know why i have so big discrepancy in execution between two apparently identical ldapsearch ?

The 1st search takes 94 ms while the 2nd one only 7 ms. It doesn't matter how many times i execute the 1st search (meaning everytihng should be already cached) .. it is always the same.

Does anyone know why?




~$ time ldapsearch  -h localhost -x -b ou=redirecting,ou=Dir,dc=ot,dc=hr  -D cn=admin,dc=ot,dc=hr -w **** uniqueID=38512303736

# extended LDIF
#
# LDAPv3
# base <ou=redirecting,ou=Dir,dc=ot,dc=hr> with scope subtree
# filter: uniqueID=38512303736
# requesting: ALL
#

# 38512303736, redirecting, Dir, ot.hr
dn: uniqueID=38512303736,ou=redirecting,ou=Dir,dc=ot,dc=hr
objectClass: top
objectClass: uniqueID
Prefix: 68A10
uniqueID: 38512303736

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1

real    0m0.094s
user    0m0.004s
sys     0m0.000s



~$ time ldapsearch  -h localhost -x -b ou=redirecting,ou=Dir,dc=ot,dc=hr  -D cn=admin,dc=ot,dc=hr -w **** uniqueID=38515000400

# extended LDIF
#
# LDAPv3
# base <ou=redirecting,ou=Direktor,dc=ot,dc=hr> with scope subtree
# filter: uniqueID=38515000400
# requesting: ALL
#

# 38515000400, redirecting, Dir, ot.hr
dn: uniqueID=38515000400,ou=redirecting,ou=Dir,dc=ot,dc=hr
objectClass: top
objectClass: uniqueID
Prefix: 68B99
uniqueID: 38515000400

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1

real    0m0.007s
user    0m0.000s
sys     0m0.004s
tculjaga@l01sipindir2:~$