[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
malloc failures with slapadd and ldapadd (ITS#1657)
Full_Name: Ashley Frost
Version: 2.0.23
OS: Tru64 v5.1
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (137.165.10.4)
My schema is simple, using only these include files: core.schema,
cosine.schema, and inetorgperson.schema.
Starting with a single ldbm definition in slapd.conf using Berkeley DB 4.0.14
using these index directives:
index objectClass,uid pres,eq
index cn,sn,givenName,ou pres,eq,sub
index mail pres,eq
I first ensure slapd is not running, and then remove everything in
openldap-ldbm
to start with a clean slate.
I then use slapadd to add a starting ldif file containing this these lines:
dn: o=williams
objectClass: organization
o: williams
description: Williams College
dn: ou=People, o=williams
objectClass: organizationalUnit
ou: People
dn: cn=Manager,ou=People,o=williams
objectClass: organizationalRole
cn: Manager
This all completes without any errors.
I then try to add an ldif file with 3346 unique records all of the form:
dn: uid=someuid,ou=People,o=williams
objectClass: inetOrgPerson
telephoneNumber: (111) 222-3333
mail: firstname.mi.lastname@williams.edu
ou: Generic Department
cn: Firstname MI Lastname
sn: Lastname
givenName: Firstname
uid: someuid
using this command line:
slapadd -c -l williams.ldif
It then runs for a while and reports:
slapadd: could not add entry dn="uid=xxx,ou=People,o=williams" (line=24629)
slapadd: could not add entry dn="uid=xxy,ou=People,o=williams" (line=24639)
slapadd: could not add entry dn="uid=xxz,ou=People,o=williams" (line=24649)
...
slapadd: could not add entry dn="uid=zzz,ou=People,o=williams" (line=24689)
Assertion failed: 0, file ch_malloc.c, line 59
Unhandled status exception 0x177db083 in thread 1, Exception: Out of memory
while processing an exception (dce / thd)
slapadd: 1183324 Abort
In the user syslog there are lines like the following:
ldbm: ==> malloc: Not enough space: 400
ldbm: ==> malloc: Not enough space: 1016
idl_insert_key: nonexistant continuation block
idl_insert_key: nonexistant continuation block
ch_realloc of 48 bytes failed
Finally,
If I change my index directives to:
index objectClass,uid pres,eq
index cn,sn,givenName pres,eq,sub
index mail pres,eq
then remove the contents of openldap-ldbm/ and repeat the above steps using the
same ldif files, everything loads without a problem.
I've tried different combinations of using index and its not related to a
particular attribute. Using: index mail,cn,sn,givenName pres,eq,sub also
fails.
If I load the ldif file using the default index directives, then change them to
what I want and use slapindex, the same type of errors occur. I've also tried
using ldapadd on a running slapd to add the same ldif file. It causes slapd to
segfault.
If it would help, I can provide a stacktrace of slapadd when this error is
generated.
Thank you for your time and patience.
Sincerely,
-Ashley Frost