bayes problem {Scanned}

Henry Hollenberg hgh at rcwm.com
Tue Oct 3 03:24:32 IST 2006


Glenn Steen wrote:
summary:  bayes manually fed several hundred SPAM/HAM and still not working.

> What you need do is either to make sure there are adequate writable
> subdirs in the home directory of the postfix user (.spamassassin,
> .razor, .pyzor ... whatever:), or explicitly place these things
> somewhere and tell the relevant subsystem/program where it is. For
> Bayes, you might have
> bayes_path /etc/MailScanner/bayes/bayes
> bayes_file_mode 0770
> 
> in your /etc/mail/spamassassin/mailscanner.cf file (note that the
> above should be a path to an existing directory + the leading
> "fragment" of the filenames the bayes files are to have...).
> If you have manually set a lot of ham/spam in _roots_ bayes files, you
> could well just move them to the new location and chown/chmod them
> appropriately. After that everything should be fine:).
> 
> Much (if not all) of this is mentioned in various places on the wiki etc 
> etc.
> 

Ok, added dir: .spamassassin, .razor, .pyzor and did chown postfix:root on them:

bastion:/var/spool/postfix# ls -la
total 88
drwxr-xr-x  22 root    root     4096 Oct  2 21:07 .
drwxr-xr-x   8 root    root     4096 Sep 26 20:41 ..
drwxr-xr-x   2 postfix root     4096 Oct  2 21:07 .pyzor
drwxr-xr-x   2 postfix root     4096 Oct  2 21:07 .razor
drwxr-xr-x   2 postfix root     4096 Oct  2 21:05 .spamassassin
drwx------  18 postfix root     4096 Jun 26  2004 active
drwx------  18 postfix root     4096 Jun 26  2004 bounce
drwx------   2 postfix root     4096 Jun 24  2004 corrupt
drwx------  18 postfix root     4096 Jun 28  2004 defer
drwx------  18 postfix root     4096 Jun 28  2004 deferred
drwxr-xr-x   2 root    root     4096 Oct  1 14:22 etc
drwx------   4 postfix root     4096 Aug 11  2004 flush
drwx------  18 postfix root     4096 Sep 29 01:00 hold
drwx------  18 postfix root     4096 Oct  2 21:07 incoming
drwxr-xr-x   2 root    root     4096 Oct  1 14:22 lib
drwx-wx--T   2 postfix postdrop 4096 Oct  1 06:25 maildrop
drwxr-xr-x   2 postfix root     4096 Jun 30  2004 pid
drwx------   2 postfix root     4096 Oct  1 14:22 private
drwx--s---   2 postfix postdrop 4096 Oct  1 14:22 public
drwx------   2 postfix root     4096 Jun 24  2004 saved
drwx------  12 postfix root     4096 Aug  8 21:32 trace
drwxr-xr-x   3 root    root     4096 Jun 24  2004 usr


Now have output of sa-learn -D --dump magic:

bastion:/var/spool/postfix# sa-learn -D --dump magic
debug: SpamAssassin version 3.0.3
debug: Score set 0 chosen.
debug: running in taint mode? yes
debug: Running in taint mode, removing unsafe env vars, and resetting PATH
debug: PATH included '/sbin', keeping.
debug: PATH included '/bin', keeping.
debug: PATH included '/usr/sbin', keeping.
debug: PATH included '/usr/bin', keeping.
debug: PATH included '/usr/bin/X11', which doesn't exist, dropping.
debug: PATH included '/usr/local/sbin', keeping.
debug: PATH included '/usr/local/bin', keeping.
debug: Final PATH set to: /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin
debug: using "/etc/spamassassin/init.pre" for site rules init.pre
debug: config: read file /etc/spamassassin/init.pre
debug: using "/usr/share/spamassassin" for default rules dir
debug: config: read file /usr/share/spamassassin/10_misc.cf
debug: config: read file /usr/share/spamassassin/20_anti_ratware.cf
debug: config: read file /usr/share/spamassassin/20_body_tests.cf
debug: config: read file /usr/share/spamassassin/20_compensate.cf
debug: config: read file /usr/share/spamassassin/20_dnsbl_tests.cf
debug: config: read file /usr/share/spamassassin/20_drugs.cf
debug: config: read file /usr/share/spamassassin/20_fake_helo_tests.cf
debug: config: read file /usr/share/spamassassin/20_head_tests.cf
debug: config: read file /usr/share/spamassassin/20_html_tests.cf
debug: config: read file /usr/share/spamassassin/20_meta_tests.cf
debug: config: read file /usr/share/spamassassin/20_phrases.cf
debug: config: read file /usr/share/spamassassin/20_porn.cf
debug: config: read file /usr/share/spamassassin/20_ratware.cf
debug: config: read file /usr/share/spamassassin/20_uri_tests.cf
debug: config: read file /usr/share/spamassassin/23_bayes.cf
debug: config: read file /usr/share/spamassassin/25_body_tests_es.cf
debug: config: read file /usr/share/spamassassin/25_hashcash.cf
debug: config: read file /usr/share/spamassassin/25_spf.cf
debug: config: read file /usr/share/spamassassin/25_uribl.cf
debug: config: read file /usr/share/spamassassin/30_text_de.cf
debug: config: read file /usr/share/spamassassin/30_text_fr.cf
debug: config: read file /usr/share/spamassassin/30_text_nl.cf
debug: config: read file /usr/share/spamassassin/30_text_pl.cf
debug: config: read file /usr/share/spamassassin/50_scores.cf
debug: config: read file /usr/share/spamassassin/60_whitelist.cf
debug: config: read file /usr/share/spamassassin/65_debian.cf
debug: using "/etc/spamassassin" for site rules dir
debug: config: read file /etc/spamassassin/local.cf
debug: using "/root/.spamassassin/user_prefs" for user prefs file
debug: config: read file /root/.spamassassin/user_prefs
debug: plugin: loading Mail::SpamAssassin::Plugin::URIDNSBL from @INC
debug: plugin: registered Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x857fef4)
debug: plugin: loading Mail::SpamAssassin::Plugin::Hashcash from @INC
debug: plugin: registered Mail::SpamAssassin::Plugin::Hashcash=HASH(0x8eb8418)
debug: plugin: loading Mail::SpamAssassin::Plugin::SPF from @INC
debug: plugin: registered Mail::SpamAssassin::Plugin::SPF=HASH(0x8e848f4)
debug: plugin: Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x857fef4) implements 'parse_config'
debug: plugin: Mail::SpamAssassin::Plugin::Hashcash=HASH(0x8eb8418) implements 'parse_config'
debug: bayes: 8558 tie-ing to DB file R/O /root/.spamassassin/bayes_toks
debug: bayes: 8558 tie-ing to DB file R/O /root/.spamassassin/bayes_seen
debug: bayes: found bayes db version 3
debug: Score set 2 chosen.
0.000          0          3          0  non-token data: bayes db version
0.000          0        752          0  non-token data: nspam
0.000          0        695          0  non-token data: nham
0.000          0      80524          0  non-token data: ntokens
0.000          0 1141401016          0  non-token data: oldest atime
0.000          0 1159706957          0  non-token data: newest atime
0.000          0          0          0  non-token data: last journal sync atime
0.000          0          0          0  non-token data: last expiry atime
0.000          0          0          0  non-token data: last expire atime delta
0.000          0          0          0  non-token data: last expire reduction count
debug: bayes: 8558 untie-ing
debug: bayes: 8558 untie-ing db_toks
debug: bayes: 8558 untie-ing db_seen


And it works!!!, I think?

X-gosemr-MailScanner-SpamCheck: not spam, SpamAssassin (score=-5.899,
	required 6, autolearn=not spam, ALL_TRUSTED -3.30, BAYES_00 -2.60), not spam, SpamAssassin (score=-2.599,
	required 6, autolearn=not spam, BAYES_00 -2.60)

Halleluja,

THankyou Glenn and of course Julian.

Kicking spam butt and liking it.

hgh.

-- 
Henry Hollenberg
hgh at rcwm.com

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
MailScanner thanks transtec Computers for their support.



More information about the MailScanner mailing list