This is how I fixed it:
# erase the wrong data that the failed restore left behind: sudo rm /var/lib/ldap/o=cejil/* # copy default DB_CONFIG sudo cp -v /usr/share/slapd/DB_CONFIG /var/lib/ldap/o=cejil # restore from the backup sudo slapadd -b o=cejil < /var/backups/slapd-2.4.11-0ubuntu6.1/o\=cejil.ldif sudo chown -vR openldap.openldap /var/lib/ldap
# start the server again sudo invoke-rc.d slapd start
This is how I fixed it:
# erase the wrong data that the failed restore left behind: ldap/o= cejil/* slapd/DB_ CONFIG /var/lib/ ldap/o= cejil slapd-2. 4.11-0ubuntu6. 1/o\=cejil. ldif
sudo rm /var/lib/
# copy default DB_CONFIG
sudo cp -v /usr/share/
# restore from the backup
sudo slapadd -b o=cejil < /var/backups/
sudo chown -vR openldap.openldap /var/lib/ldap
# start the server again
sudo invoke-rc.d slapd start