From 4fa2ee84eb3dfdfd202585a59403195b408bbb8f Mon Sep 17 00:00:00 2001 From: Rich Megginson Date: Mon, 26 Apr 2010 17:26:00 -0600 Subject: Bug 572018 - Upgrading from 1.2.5 to 1.2.6.a2 deletes userRoot https://bugzilla.redhat.com/show_bug.cgi?id=572018 Resolves: bug 572018 Bug Description: Upgrading from 1.2.5 to 1.2.6.a2 deletes userRoot Reviewed by: self Branch: HEAD Fix Description: According to the error message, the entry id cannot be found in the id2entry file. The entry id comes from the parentid index, which has just been created by the dn2rdn upgradedb process. The entryid is the key in the parentid index. I'm not sure how this can happen - either the parentid contains the id of an entry that does not exist, or the entryid was somehow corrupted. I've added some additional debugging statements to try to narrow this down. Platforms tested: RHEL5 x86_64 Flag Day: no Doc impact: no --- ldap/servers/slapd/back-ldbm/ancestorid.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ldap/servers/slapd/back-ldbm/ancestorid.c b/ldap/servers/slapd/back-ldbm/ancestorid.c index 768dc6e7..1337e037 100644 --- a/ldap/servers/slapd/back-ldbm/ancestorid.c +++ b/ldap/servers/slapd/back-ldbm/ancestorid.c @@ -464,6 +464,9 @@ static int ldbm_ancestorid_new_idl_create_index(backend *be) while (1) { ret = ldbm_parentid(be, txn, id, &parentid); if (ret != 0) { + slapi_log_error(SLAPI_LOG_FATAL, sourcefile, + "Error: ldbm_parentid on node index [" ID_FMT "] of [" ID_FMT "]\n", + nids, nodes->b_nids); idl_free(children); goto out; } @@ -552,6 +555,9 @@ static int ldbm_parentid(backend *be, DB_TXN *txn, ID id, ID *ppid) ret = db->get(db, txn, &key, &data, 0); if (ret != 0) { ldbm_nasty(sourcefile,13110,ret); + slapi_log_error(SLAPI_LOG_FATAL, sourcefile, + "Error: unable to find entry id [" ID_FMT "] (original [" ID_FMT "])" + " in id2entry\n", stored_id, id); goto out; } -- cgit