Re: git: 0cea189105ef - main - databases/lmdb: add migration notice for 0.9.x -> 1.0.0 upgrade
Date: Fri, 10 Jul 2026 03:26:20 UTC
On Thu, Jul 09, 2026 at 07:39:38AM +0200, Daniel Engberg wrote: > On 2026-07-09 07:08, Kevin Bowling wrote: > > On Wed, Jul 8, 2026 at 9:31 PM Koichiro Iwao<meta@freebsd.org> wrote: > > > On Thu, Jul 02, 2026 at 05:36:12PM +0000, Xin LI wrote: > > > > +20260702: > > > > + AFFECTS: users of databases/lmdb > > > > + AUTHOR:delphij@FreeBSD.org > > > > + > > > > + LMDB 1.0 introduced an incompatible on-disk file format change. > > > > + Versions 0.9.x and 1.0.x databases are mutually incompatible. > > > > + > > > > + Before upgrading, export all existing databases using the old v0.9 > > > > + mdb_dump utility, then import them with the new v1.0 mdb_load after > > > > + upgrading. There is no support for opening v0.9 database files > > > > + directly with LMDB 1.0. > > > > + > > > > + Example migration procedure: > > > > + # mdb_dump -a /path/to/db > /tmp/mydb.dump > > > > + # pkg upgrade databases/lmdb > > > > + # mdb_load -f /tmp/mydb.dump /path/to/newdb > > > > + > > > I may be a bit late but nobody else has mentioned this, I don't believe > > > it is particularly useful. > > > > > > Rather than being used directly by end users, LMDB is used by other > > > ports as an internal dependency to store their data. > > > > > > Most users are unlikely to know how many LMDB database files exist on > > > their entire filesystem or where they are located. I would say requiring > > > end users to migrate files owned by numerous dependent ports is absurd. > > It's definitely an awkward move by the upstream author. I was > > interested in using LMDB somewhere but now it suffers the same myopia > > as BDB and other competitors. sqlite ends up being the right choice > > almost always because of games like this. > > > > > -- > > > meta<meta@FreeBSD.org> > > > > I don't see how upstream could mandate how it's used downstream and it's not > uncommon for database software to require updates of the database structure > itself. That's right. Upstream does not mandate that doewnstream to LMDB 1.0. The problem was that every consumer was switched to 1.0 at once, even though the migration wasn't required. Users generally don't care wheteher an application uses LMDB internally. I thought it would be more helpful to have the UPDATING entry under each affected ports rather than "users of databases/lmdb", since that wuold make it easier for users to tell whether they're affected. Anyway, I'm happy with the current approach, which allows both 0.9 and 1.0 to coexist. > fwiw, as for sqlite3 at least on FreeBSD we don't have a working unit test > suite (it's been reported and there's a PR) since at least upgrading to > 3.53.X > > Best regards, > Daniel -- meta <meta@FreeBSD.org>