On Tue, Jun 24, 2014 at 11:31 AM, Alessandro Avagliano alessandro@avagliano.berlin wrote:
On 24/06/14 16:10, Mauricio Tavares wrote:
I does sound like the database is corrupted somehow. slapcat
needs slapd to be running, right?
Hello Mauricio,
Hello and thanks for the reply. I will save it in my notes. That said, the original poster was Eileen, not me.
I do hope she'll try your suggestions and get the data back.
(If you don't have a backup... ) ...depending on your operating system and OpenLDAP version installed, you should have on your system a tool called db<version>_recover
e.g.: db5.1_recover, db4.8_recover and so on.
(from the man page:) "db5.1_recover - Restore the database to a consistent state
The db5.1_recover utility must be run after an unexpected application, Berkeley DB, or system failure to restore the database to a consistent state. All committed transactions are guaranteed to appear after db5.1_recover has run, and all uncommitted transactions will be completely undone."
Be sure to make a backup copy of your db before running it, and that the version of the db utilities that you are running matches your BDB version (I haven't tried to recover it using different utilities/db version).
If you manage to restore your db, make sure you perform regular backups and that you have at least 1 slapd replica running.... they can both help you to restore the system in such situations
I hope this helps,
Kind Regards, Alessandro
openldap-technical@openldap.org