[Rspamd-Users] Questions about REDIS and Bayes Learning
Sophie Loewenthal
sophie at klunky.co.uk
Mon Nov 19 10:08:55 UTC 2018
Hi,
Watching this thread for a while and wondered if mine made sense.
Why does rspamc stat report 284 spam learnt, but HGETALL RS reports 417 spam?
Best, Sophie
# rspamc stat|grep Stat
Statfile: BAYES_SPAM type: redis; length: 9.62M; free blocks: 0; total blocks: 253.25k; free: 0.00%; learned: 284; users: 2; languages: 0
Statfile: BAYES_HAM type: redis; length: 18.94M; free blocks: 0; total blocks: 498.44k; free: 0.00%; learned: 658; users: 2; languages: 0
# rspamadm configdump classifier.bayes.min_learns
*** Section classifier.bayes.min_learns ***
200
*** End of section classifier.bayes.min_learns ***
# redis-cli HGETALL RS
1) "learns_spam"
2) "355"
3) "learns_ham"
4) "417"
#
> On 19 Nov 2018, at 09:28, Alexander Moisseev via Users <users at lists.rspamd.com> wrote:
>
> On 19.11.18 10:48, Tim Harman via Users wrote:
>> On 19/11/2018 7:21 pm, Alexander Moisseev via Users wrote:
>>> On 19.11.18 3:02, Tim Harman via Users wrote: On 16/11/2018 9:43 pm, Manuel Garbin wrote:
>>>
>>> Hi Tim,
>>> autolearn will autofeed the bayes DB, that mean that you have 200+ learned.
>>> For your question :
>>>
>>> 1) I've used same command to clean a redis cache, it works
>>> 2) disable autolearn if you want use manual learn
>>> 3) use header + body and remove the X-spam status header
>>> With regards to the first part:
>>>
>>> 127.0.0.1:6379> HGETALL RS
>>> 1) "learns_spam"
>>> 2) "100"
>>> 3) "learns_ham"
>>> 4) "52"
>>> 5) "version"
>>> 6) "2"
>>>
>>> This seems to imply that less than 200 of both have been learnt? Or am
>>> I using the wrong REDIS command?
>> The command is correct. You can get the same counters using `rspamc
>> stat` command.
>> At minimum, 200 ham and 200 spam mails need to be learnt.
>> Thanks, that's what I thought.
>> So my rspamc stat says:
>> Statfile: BAYES_SPAM type: redis; length: 0; free blocks: 0; total
>> blocks: 0; free: 0.00%; learned: 109; users: 1; languages: 0
>> Statfile: BAYES_HAM type: redis; length: 0; free blocks: 0; total
>> blocks: 0; free: 0.00%; learned: 61; users: 1; languages: 0
>> Total learns: 170
>> But I'm getting messages like so:
>> BAYES_HAM (-3) [100.00%]
>> BAYES_HAM (-0.318029) [75.54%]
>> BAYES_SPAM (5.1) [100.00%]
>> In my rspamd reports.
>> Have I hit a minor bug here? It doesn't really bother me, it seems to
>> be doing a great job of knowing what is spam and what's ham.
>> But it seems the rules in the doco/config aren't actually being
>> implemented.
>
> Please run `spamadm configdump classifier.bayes.min_learns`. Does it return 200?
> --
> Users mailing list
> Users at lists.rspamd.com
> https://lists.rspamd.com/mailman/listinfo/users
More information about the Users
mailing list