sqlite problems on Mac OS X 10.4

Matthias Andree matthias.andree at gmx.de
Sat Sep 10 11:07:14 CEST 2005


On Fri, 09 Sep 2005, Jim Correia wrote:

> >Yes, concurrency was removed from the Berkeley DB backend, albeit  
> >for different
> >reasons (namely that the lock table sizing was difficult to get  
> >right).
> 
> bogofilter ensures data integrity using some other mechanism for  
> multiple concurrent processes when using BDB?

Yes, we use "manual" fcntl()-style locks.

> I think there is a bug here (perhaps in sqlite and/or how the locking  
> mechanism works on Mac OS X) but I don't know how to proceed further.  
> If I ratchet the test down to 2 concurrent instances, it still hangs.

Given the test also passes on FreeBSD, from which Darwin (the core
operating system underneath MacOS X is derived), I find that somewhat
unlikely.

> If I hardcode bf_sleep to use 10 microseconds rather than the passed  
> in value (in an attempt to make things complete faster) I get
> 
> retrying registration after avoided deadlock...
> ...[repeat many times]
> retrying registration after avoided deadlock...
> retry count exceeded, giving up.
> #### Part 2 ####
> 
> And we end up right back where we started.

Perhaps we need to let the process sleep longer rather than shorter, so
that one process can complete while the other sleeps.

-- 
Matthias Andree



More information about the bogofilter-dev mailing list