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

Converting From gdbm to bdb



Attempting to convert OpenLDAP v2.0.27-11 configured for gdbm to OpenLDAP v2.2.26 configured for bdb.
 
I have successfully compiled OpenLDAP v2.2.26 and all its prerequisites (Berkeley v4.3.28, etc)
 
I used slapcat on the 2.0.27 server to get a backup of the ldap gdbm database.
 
I run the following command on the 2.2.26 server and get the following error:
 
/usr/local/sbin/slapadd -f /etc/openldap/slapd.schemacheck-off -l /home/ldap-backup/Jul11-0345
slapadd: could not add entry dn="ou=gtis,ou=van1,ou=pac,o=pwgsc" (line=8): txn_aborted! DB_KEYEXIST: Key/data pair already exists (-30996)
 
Here is a copy of slapd.schemacheck-off:
 
include /etc/openldap/schema/core.schema
include /etc/openldap/schema/cosine.schema
include /etc/openldap/schema/inetorgperson.schema
include /etc/openldap/schema/nis.schema
include /etc/openldap/schema/redhat/autofs.schema
#include /etc/openldap/schema/redhat/kerberosobject.schema
include /etc/openldap/schema/fw1ng.schema
 
#
# Certificates for TLS Connections
# Set ownership to ldap:ldap and mode 600
TLSCertificateFile /usr/share/ssl/certs/slapd.pem
TLSCertificateKeyFile /usr/share/ssl/certs/slapd.pem
 
# ===========================================
#                 Access Control
# ===========================================
access to dn="" by * read
 
access to attr=entry,cn,uid,description,mail,member
  by dn="cn=Firewall Admin,o=pwgsc" write by * read
 
access to attr=userpassword
  by self write
  by dn="cn=Firewall,o=pwgsc" write
  by anonymous auth
 
access to attr=fw1pwdlastmod,fw1badPwdCount,fw1lastLoginFailure,fw1userPwdPolicy
  by dn="cn=Firewall,o=pwgsc" write
  by dn="cn=Firewall Admin,o=pwgsc" write
  by * none
 
access to attr=fw1auth-method,fw1auth-server,fw1skey-number,fw1skey-seed,fw1skey-passwd,fw1skey-mdm,fw1expiration-date,fw1hour-range-from,fw1hour-range-to,fw1day,fw1allowed-src,fw1allowed-dst,fw1allowed-vlan,fw1SR-keym,fw1SR-datam,fw1SR-mdm,fw1enc-fwz-expiration,fw1sr-auth-track,fw1grouptemplate,fw1ISAKMP-EncMethod,fw1ISAKMP-AuthMethods,fw1ISAKMP-HashMethods,fw1ISAKMP-Transform,fw1ISAKMP-DataIntegrityMethod,fw1ISAKMP-SharedSecret,fw1ISAKMP-DataEncMethod,fw1enc-methods,fw1userPwdPolicy,memberoftemplate,memberOf
  by dn="cn=Firewall,o=pwgsc" read
  by dn="cn=Firewall Admin,o=pwgsc" write
  by * none
 
access to *
  by self write
  by users read
  by anonymous auth
 
# Schema check must be turned off when using slapadd to build database!
schemacheck off
 
#######################################################################
# ldbm database definitions
#######################################################################
 
database bdb
 
suffix  "o=pwgsc"
 
rootdn  "cn=admin,o=pwgsc"
 
rootpw  {CRYPT}iWkhys7q1iVpM
 
directory /var/lib/ldap
 
# Indices to maintain
index   objectClass,uid,uidNumber,gidNumber,memberUid   eq
index cn,mail,surname,givenname   eq,subinitial