ovdb instability with Berkeley DB5/6

Julien ÉLIE julien at trigofacile.com
Sun Sep 15 14:46:51 UTC 2019


Hi,

> Env: FreeBSD 12 - amd64, INN 2.6.3
> 
> The trouble came when using 'makehistory -O -x -F' to build my ovdb.  I
> started with the precompiled Berkeley DB 5.3 from the FreeBSD ports
> system.  I couldn't get it to be stable.  At first, I had mmap on.  That
> was very unstable.  It would die and corrupt the DB.  It wouldn't
> recover.  Then I turned on shared memory instead.  Things were slightly
> more stable, but it would eventually hang.  When I did an 'ovdb_stat
> -t', I would see there was a single transaction running.  I tried lots
> of other parameters randomly.  I figure I have pretty good coverage of
> them at this point.

What is the setting of the "readserver" parameter in ovdb.conf?
The recommended setting is "true".  It permits cleaner shutdowns for the 
database, improves stability and avoids deadlocks and corrupted databases.

I understand from your experience with recent BDB versions that "useshm" 
set to true improves stability with FreeBSD.



> My experience was about the same with BDB 6.2.
> 
> I finally switched back to BDB 4.8, which is EoL.  With that and shared
> memory, it was stable enough to build ovdb (about 20 hours).  Everything
> looks good so far.
> > I was upgrading from 2.5.3 and I can't remember what version of BDB I
> was using way back then.  It was probably another 4.x version.  That was
> rock solid for years.  Hopefully I've gotten it back into a good state.

I bet there hasn't been much testing with BDB 5.x, 6.x and now 18.x 
versions...  Our code surely needs subtle adaptations to make it as 
stable as it used to be with 4.x versions.



> If this happens again, do folks have thoughts on how to debug it?

When you say above "It would die and corrupt the DB", do you mean innd 
dies, or an ovdb process, or makehistory?  If you can get a stack trace, 
it would probably be helpful.

-- 
Julien ÉLIE

« Les légionnaires ont adopté pour attaquer la redoutable tactique
   dite de la tortue. Pour battre en retraite, les légionnaires adoptent
   l'efficace tactique dite du lièvre. » (Astérix)


More information about the inn-workers mailing list