I have gone through documentation online and on some forums but I am stuck on importing data from ldap 2.4 to 2.5 (Migrating to a new server as well). Here are the steps I did and the error I am receiving. (There were multiple other errors but that is fixed now
Installation that I performed for 2.5:
sudo ./configure --prefix=/usr --sysconfdir=/etc --disable-static --enable-debug --with-tls=openssl --with-cyrus-sasl --enable-dynamic /
--enable-crypt --enable-spasswd --enable-slapd --enable-modules --enable-rlookups --enable-overlays=yes --enable-ldap=yes /
--enable-ppolicy=yes --enable-accesslog=yes --enable-mdb=yes --disable-ndb --disable-sql
Slaptest my slapd.conf file :
slaptest -f /etc/openldap/slapd.conf.template -F /etc/openldap/slapd.d -u
config file testing succeeded
slaptest -f /etc/openldap/slapd.conf.template -F /etc/openldap/slapd.d
config file testing succeeded
After this is completed there is some content under /etc/openldap/slapd.d, and I changed the permission to the ldap user. The content:
'cn=config' 'cn=config.ldif'
##Now I want to import my data file with slapadd. With -u (dryrun) there are no errors but without it I am receiving the following:
slapadd -n 1 -F /etc/openldap/slapd.d -l data.ldif
mdb_id2entry_put: mdb_put failed: MDB_KEYEXIST: Key/data pair already exists(-30799) "dc=test,dc=com"
=> mdb_tool_entry_put: id2entry_add failed: err=-30799
=> mdb_tool_entry_put: txn_aborted! MDB_KEYEXIST: Key/data pair already exists (-30799)
slapadd: could not add entry dn="dc=test,dc=com" (line=1): txn_aborted! MDB_KEYEXIST: Key/data pair already exists (-30799)
Closing DB...
Any suggestions please?. Thanks