#50574 remove bdb upgrade code
Opened 2 months ago by lkrispen. Modified 2 months ago

in the backend, in the versiion file the database version is tracked and at satrup and especially in restore it is checked and compared with the version of the installed libdb.

But this goes back ages:

 #define LDBM_VERSION_BASE        "Netscape-ldbm/" 
 #define LDBM_VERSION             "Netscape-ldbm/7.0" /* db42: new idl -> old */
 #define LDBM_VERSION_NEW         "Netscape-ldbm/7.0_NEW"     /* db42: new idl */
 #define LDBM_VERSION_OLD         "Netscape-ldbm/7.0_CLASSIC" /* db42: old idl */
 #define LDBM_VERSION_62          "Netscape-ldbm/6.2" /* db42: old idl */
 #define LDBM_VERSION_61          "Netscape-ldbm/6.1" /* db33: old idl */
 #define LDBM_VERSION_60          "Netscape-ldbm/6.0" /* db33: old idl */
 #define LDBM_VERSION_50          "Netscape-ldbm/5.0"
 #define LDBM_VERSION_40          "Netscape-ldbm/4.0"
 #define LDBM_VERSION_30          "Netscape-ldbm/3.0"
 #define LDBM_VERSION_31          "Netscape-ldbm/3.1"

we are using 5.3 for quite some time and will probably never move to 6.x
so lets remove the reference to these old versions and all the related upgrade code.


To confirm, what version of libdb is RH/Fedora using? suse is on db48 ...

Metadata Update from @firstyear:
- Custom field origin adjusted to None
- Custom field reviewstatus adjusted to None

2 months ago

RHEL 7 and 8 use 5.3, Fedora as well, don't remember since which version.
RHEL 6 was using 4.7.

Could you provide the content of the DBVERSION file in curren SUSE install ?

dirsrv@ldapkdc:/data/db> cat DBVERSION
bdb/4.8/libback-ldbm/newidl/rdn-format-3/dn-4514-1

Wondering if it's worth upgrading to libdb 5.3 on SUSE in this case. I'll need to check about licensing and with the current maintainer.

So I think we can remove up to libdb v4 if that's okay? Are there any required upgrade steps between 4.8 and 5.3 in the code?

yes, a closer look shows that the bdb upgrade is just a rename of the database file extension from .db4 to .db, of course using a database environment and the proper bdb ->rename function :-)

The bulk of the upgrade code is for the other stuff:
- eg there is an ugradedbdnformat which handles old dns which were not properly normalized (ontaining multiple spaces or quotes).
- or for entryrdn and idl-switch.

So I will remove the upgrade code relating to older versions < 4 and the "Netscape,xx" stuff.
The handling of idl and entryrdn will be done in the ticket about single DBVERSION file

Sounds good to me :) I'm following up inside of suse to get 5_3 added so we can be on the same version with RH/Fedora. Thanks!

Metadata Update from @mreynolds:
- Issue set to the milestone: 1.4.2

2 months ago

Login to comment on this ticket.

Metadata