bogofilter randomly fails to find db's

David Relson relson at osagesoftware.com
Sat Jan 10 01:14:49 CET 2004


On Fri, 9 Jan 2004 15:52:07 -0800
Chris Wilkes <cwilkes-bf at ladro.com> wrote:

> On Sat, Jan 10, 2004 at 12:27:04AM +0100, Roger 'Rocky' Vetterberg
> wrote:
> > 
> > >Second, having separate databases is the old way of doing things
> > >and has been deprecated.  It would be best if you'd run
> > >"bogoupgrade -d/var/lib/bogofilter" which will read the separate
> > >databases and will create a new, combined database named
> > >wordlist.db.  Bogofilter will use wordlist.db instead of
> > >spamlist.db and goodlist.db.
> > 
> > I tried, but no luck.
> > 
> > rambo# bogoupgrade -d /var/lib/bogofilter
> > Can't open file '/var/lib/bogofilter/goodlist.db'
> > error running "bogoutil -d /var/lib/bogofilter/goodlist.db":  at 
> > /usr/local/bin/bogoupgrade line 158.
> 
> Can you use bogoutil on the old good|goolists.db's?  If so you could
> try doing a 
>   for i in goodlist.db spamlist.db; do
>     bogoutil -d $i | bogoutil -l $i-new;
>     mv $i $i-`date +%s` && mv $i-new $i;
>   done
> and see if rebuilding those databases does the trick.
> 
> Chris

Chris,

The drawback of your approach is that it creates new, separate
wordlists.  Bogofilter support for separate wordlists has been
depreceated (as of 0.16.0) and will be removed totally in 0.17.0.  The
attached script, bogoupgrade.sh, is an alternate implementation of
bogoupgrade that will do the merge.

Rocky,

I was under the impression that you were starting afresh with a new
database, rather than making repeated attempts to work with an existing
database.  Once a database is b0rked, "bogoutil -d" and "db_dump" are
salvage tools.  Typically they can recover sum, but not all of the
database.

Did you ever try running db_verify to check the state of your databases?

I don't recall all the details of your situation but BerkelyDB doesn't
like version mismatches.  In particular a program built with 3.x will
fail if it tries to read a database created with 4.x.  Running "file
*list.db" will tell you the database version (8 corresponds to 3.x and 9
to 4.x) and "ldd bogofilter" will indicate which shared library is being
used.

Anyhow, I'm glad to hear you're up and running.  'Tis fine by me that
you found a solution on your own.  Good work!!

David
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bogoupgrade.sh
Type: application/x-sh
Size: 527 bytes
Desc: not available
URL: <http://www.bogofilter.org/pipermail/bogofilter/attachments/20040109/9f1caf09/attachment.sh>


More information about the Bogofilter mailing list