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

linux slapadd: backend_startup: bi_db_open failed! (-1)



I have manually compiled and installed the following packages:

cyrus-sasl-2.1.12
db-4.1.25
krb5-1.2.7
openldap-2.1.14

Everything has been working right so far except for one thing:

linux slapadd: bdb_db_init: Initializing BDB database
linux slapadd: backend_startup: bi_db_open failed! (-1)
linux slapadd: bdb_initialize: Sleepycat Software: Berkeley DB 4.1.25:
(December 19, 2002)

The above error is generated when using the following slapd.conf:

# $OpenLDAP: pkg/ldap/servers/slapd/slapd.conf,v 1.8.8.4 2000/08/26 17:06:18
kurt Exp $
#
# See slapd.conf(5) for details on configuration options.
# This file should NOT be world readable.
#
include         /usr/local/etc/openldap/schema/core.schema
include         /usr/local/etc/openldap/schema/cosine.schema
include         /usr/local/etc/openldap/schema/inetorgperson.schema
#include        /usr/local/etc/openldap/schema/nis.schema
#include        /usr/local/etc/openldap/schema/redhat/rfc822-MailMember.schema
#include        /usr/local/etc/openldap/schema/redhat/autofs.schema
#include        /usr/local/etc/openldap/schema/redhat/kerberosobject.schema

# Define global ACLs to disable default read access.

# Do not enable referrals until AFTER you have a working directory
# service AND an understanding of referrals.
#referral       ldap://root.openldap.org

pidfile         /var/run/slapd.pid
argsfile        /var/run/slapd.args

# Load dynamic backend modules:
# modulepath    /usr/sbin/openldap
# moduleload    back_ldap.la
# moduleload    back_ldbm.la
# moduleload    back_passwd.la
# moduleload    back_shell.la

# To allow TLS-enabled connections, create /usr/share/ssl/certs/slapd.pem
# and uncomment the following lines.
# TLSCertificateFile /usr/share/ssl/certs/slapd.pem
# TLSCertificateKeyFile /usr/share/ssl/certs/slapd.pem

#######################################################################
# bdb database definitions
#######################################################################

database        bdb
#suffix         "dc=itarchitect,dc=ca"
suffix          "o=itarchitect"
suffix          "dc=ldap,dc=itarchitect,dc=ca"
rootdn          "cn=DirectoryAdmin,o=itarchitect"
rootpw          {SHA}13kqeC5z7cV4fHTrG0z91Qz6+uk=
directory       /usr/local/var/openldap-data
#defaultaccess   read
schemacheck     onlastmod         on
#allow          *
# Indices to maintain
#index  objectClass                             eq
#index  objectClass,uid,uidNumber,gidNumber     eq
#index  cn,mail,surname,givenname               eq,subinitial
index   cn,sn,st                                pres,eq,sub

For some reason, the bdb related error only happens with the above
configuration. However, if I use the slapd.conf.default and I tweak the
default values, my databases get created without any problems. Therefore, I
am wondering if this is a bug with OpenLDAP? Any suggestions? Also, what is
the proper syntax for slapadd when trying to add the following
itarchitect.ldif file (after I get this to work that is):

dn: dc=ldap,dc=itarchitect,dc=ca
objectClass: top
objectclass: dcObject
objectclass: organization
dc: itarchitect
o: itarchitect
description: IT Architecture Research & Development Domain

dn: o=itarchitect
objectClass: top
objectClass: organization
o: itarchitect
description: IT Architecture Research & Development

dn: cn=DirectoryAdmin,o=itarchitect
objectClass: organizationalRole
cn: DirectoryAdmin
description: LDAP Directory Administrator

dn: ou=MemberGroupA,o=itarchitect
ou: MemberGroupA
objectClass: top
objectClass: organizationalUnit
description: Members of MemberGroupA

I'm new to OpenLDAP so perhaps I missed something? Maybe OpenLDAP just isn't
100% compatible with the latest BerkeleyDB? Should I be using ldbm instead
of bdb?