Re: Re: spamprobe-1.1x7 released
Brian Burton <[email protected]>
| Newsgroups | gmane.mail.spam.spamprobe.general |
|---|---|
| Message-ID | <[email protected]> |
David A. Lee wrote: > Say I wanted to do this manually ... either for my first Hash DB or future ones. > How does one calcuate a decent size for a hash DB given a current DB (either a PBL or Hash) ? Hmm. In bash it might be something like this: expr 24 '*' `spamprobe dump|wc -l` / 1024 / 1024 Or as a script something like this (haven't tested it): NUMTERMS=`spamprobe dump|wc -l` NEWSIZE=`expr '*' $NUMTERMS / 1024 / 1024` Then you could do an export/import spamprobe export > sptemp.export mkdir newdb spamprobe -d hash:$NEWSIZE:newdb import < sptemp.export mv .spamprobe old.spamprobe mv newdb .spamprobe Or for the final swap you could be more bold and just move the new file over the old one: spamprobe exec mv newdb/sp_words.hash .spamprobe Not sure if that would work. All the best, ++Brian ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click