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

alias support



All,

I was wondering what the status of alias support is in openldap 2.2.18
with an ldbm backend or bdb backend.  If its not supported, I was
wondering if anyone could offer any advice on other ways of doing this?

Right now, I am having trouble with it.  When I do an ldapsearch with -a
never, the entry comes back as expected.  However, when I do an ldapsearch
with -a always, I don't get any results.

I was originally using bdb, but thought I remembered something about
aliases not supported on bdb, so I switched to ldbm.

Thanks for any help or advice.

Here are my users doing a direct ldapsearch

ldapsearch -D "cn=root,dc=webhamster" -w secret -b dc=webhamster
"(uid=dusty)"

# dusty, users, webhamster
dn: uid=dusty,ou=users,dc=webhamster
objectClass: alias
objectClass: extensibleObject
uid: dusty
userPassword:: ZHVzdHk=
aliasedObjectName: accountNumber=1,ou=accounts,dc=webhamster


ldapsearch -D "cn=root,dc=webhamster" -w secret -b dc=webhamster
"(accountNumber=1)"

# 1, accounts, webhamster
dn: accountNumber=1,ou=accounts,dc=webhamster
objectClass: accountprofile
accountNumber: 1
accessCode: premium


Now, when I do an ldapsearch for the uid=dusty, with -a always, I get no
results.

# ldapsearch -a always -D "cn=root,dc=webhamster" -w secret -b dc=webhamster
"(uid=dusty)"

# extended LDIF
#
# LDAPv3
# base <dc=webhamster> with scope sub
# filter: (uid=dusty)
# requesting: ALL
#

# search result
search: 2
result: 0 Success

# numResponses: 1


Here is what running slapd -d6 shows me with -a always

connection_get(9)
ldap_read: want=8, got=8
  0000:  30 27 02 01 01 60 22 02                            0'...`".
ldap_read: want=33, got=33
  0000:  01 03 04 15 63 6e 3d 72  6f 6f 74 2c 64 63 3d 77
....cn=root,dc=w
  0010:  65 62 68 61 6d 73 74 65  72 80 06 73 65 63 72 65
ebhamster..secre
  0020:  74                                                 t
ldap_read: want=8 error=Resource temporarily unavailable
==> ldbm_back_bind: dn: cn=root,dc=webhamster
send_ldap_result: err=0 matched="" text=""
  0000:  30 0c 02 01 01 61 07 0a  01 00 04 00 04 00         0....a........
ldap_write: want=14, written=14
  0000:  30 0c 02 01 01 61 07 0a  01 00 04 00 04 00         0....a........
connection_get(9)
ldap_read: want=8, got=8
  0000:  30 33 02 01 02 63 2e 04                            03...c..
ldap_read: want=45, got=45
  0000:  0d 64 63 3d 77 65 62 68  61 6d 73 74 65 72 0a 01
.dc=webhamster..
  0010:  02 0a 01 03 02 01 00 02  01 00 01 01 00 a3 0c 04
................
  0020:  03 75 69 64 04 05 64 75  73 74 79 30 00            .uid..dusty0.
ldap_read: want=8 error=Resource temporarily unavailable
SRCH "dc=webhamster" 2 3    0 0 0
    filter: (uid=dusty)
    attrs:
ldbm_cache_open (blksize 16384) (maxids 4094) (maxindirect 3)
ldbm_cache_open (blksize 16384) (maxids 4094) (maxindirect 3)
ldbm_cache_open (blksize 16384) (maxids 4094) (maxindirect 3)
ldbm_cache_open (blksize 16384) (maxids 4094) (maxindirect 3)
ldbm_cache_open (blksize 16384) (maxids 4094) (maxindirect 3)
send_ldap_result: err=0 matched="" text=""
  0000:  30 0c 02 01 02 65 07 0a  01 00 04 00 04 00         0....e........
ldap_write: want=14, written=14
  0000:  30 0c 02 01 02 65 07 0a  01 00 04 00 04 00         0....e........
connection_get(9)
ldap_read: want=8, got=7
  0000:  30 05 02 01 03 42 00                               0....B.
ldap_read: want=8, got=0


Now with -a never

connection_get(9)
ldap_read: want=8, got=8
  0000:  30 27 02 01 01 60 22 02                            0'...`".
ldap_read: want=33, got=33
  0000:  01 03 04 15 63 6e 3d 72  6f 6f 74 2c 64 63 3d 77
....cn=root,dc=w
  0010:  65 62 68 61 6d 73 74 65  72 80 06 73 65 63 72 65
ebhamster..secre
  0020:  74                                                 t
ldap_read: want=8 error=Resource temporarily unavailable
==> ldbm_back_bind: dn: cn=root,dc=webhamster
send_ldap_result: err=0 matched="" text=""
  0000:  30 0c 02 01 01 61 07 0a  01 00 04 00 04 00         0....a........
ldap_write: want=14, written=14
  0000:  30 0c 02 01 01 61 07 0a  01 00 04 00 04 00         0....a........
connection_get(9)
ldap_read: want=8, got=8
  0000:  30 33 02 01 02 63 2e 04                            03...c..
ldap_read: want=45, got=45
  0000:  0d 64 63 3d 77 65 62 68  61 6d 73 74 65 72 0a 01
.dc=webhamster..
  0010:  02 0a 01 00 02 01 00 02  01 00 01 01 00 a3 0c 04
................
  0020:  03 75 69 64 04 05 64 75  73 74 79 30 00            .uid..dusty0.
ldap_read: want=8 error=Resource temporarily unavailable
SRCH "dc=webhamster" 2 0    0 0 0
    filter: (uid=dusty)
    attrs:
  0000:  30 81 c0 02 01 02 64 81  ba 04 20 75 69 64 3d 64   0.....d...
uid=d
  0010:  75 73 74 79 2c 6f 75 3d  75 73 65 72 73 2c 64 63
usty,ou=users,dc
  0020:  3d 77 65 62 68 61 6d 73  74 65 72 30 81 95 30 28
=webhamster0..0(
  0030:  04 0b 6f 62 6a 65 63 74  43 6c 61 73 73 31 19 04
..objectClass1..
  0040:  05 61 6c 69 61 73 04 10  65 78 74 65 6e 73 69 62
.alias..extensib
  0050:  6c 65 4f 62 6a 65 63 74  30 0e 04 03 75 69 64 31
leObject0...uid1
  0060:  07 04 05 64 75 73 74 79  30 17 04 0c 75 73 65 72
...dusty0...user
  0070:  50 61 73 73 77 6f 72 64  31 07 04 05 64 75 73 74
Password1...dust
  0080:  79 30 40 04 11 61 6c 69  61 73 65 64 4f 62 6a 65
y0@..aliasedObje
  0090:  63 74 4e 61 6d 65 31 2b  04 29 61 63 63 6f 75 6e
ctName1+.)accoun
  00a0:  74 4e 75 6d 62 65 72 3d  31 2c 6f 75 3d 61 63 63
tNumber=1,ou=acc
  00b0:  6f 75 6e 74 73 2c 64 63  3d 77 65 62 68 61 6d 73
ounts,dc=webhams
  00c0:  74 65 72                                           ter
ldap_write: want=195, written=195
  0000:  30 81 c0 02 01 02 64 81  ba 04 20 75 69 64 3d 64   0.....d...
uid=d
  0010:  75 73 74 79 2c 6f 75 3d  75 73 65 72 73 2c 64 63
usty,ou=users,dc
  0020:  3d 77 65 62 68 61 6d 73  74 65 72 30 81 95 30 28
=webhamster0..0(
  0030:  04 0b 6f 62 6a 65 63 74  43 6c 61 73 73 31 19 04
..objectClass1..
  0040:  05 61 6c 69 61 73 04 10  65 78 74 65 6e 73 69 62
.alias..extensib
  0050:  6c 65 4f 62 6a 65 63 74  30 0e 04 03 75 69 64 31
leObject0...uid1
  0060:  07 04 05 64 75 73 74 79  30 17 04 0c 75 73 65 72
...dusty0...user
  0070:  50 61 73 73 77 6f 72 64  31 07 04 05 64 75 73 74
Password1...dust
  0080:  79 30 40 04 11 61 6c 69  61 73 65 64 4f 62 6a 65
y0@..aliasedObje
  0090:  63 74 4e 61 6d 65 31 2b  04 29 61 63 63 6f 75 6e
ctName1+.)accoun
  00a0:  74 4e 75 6d 62 65 72 3d  31 2c 6f 75 3d 61 63 63
tNumber=1,ou=acc
  00b0:  6f 75 6e 74 73 2c 64 63  3d 77 65 62 68 61 6d 73
ounts,dc=webhams
  00c0:  74 65 72                                           ter
send_ldap_result: err=0 matched="" text=""
  0000:  30 0c 02 01 02 65 07 0a  01 00 04 00 04 00         0....e........
ldap_write: want=14, written=14
  0000:  30 0c 02 01 02 65 07 0a  01 00 04 00 04 00         0....e........
connection_get(9)
ldap_read: want=8, got=7
  0000:  30 05 02 01 03 42 00                               0....B.
ldap_read: want=8, got=0