LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-15-2015, 12:43 PM   #1
daemoncesar
LQ Newbie
 
Registered: Feb 2015
Posts: 22

Rep: Reputation: Disabled
amavisd-new + sa-learn + spamassassin


Hello !

The sa-learn command does not work in amavisd-new.


/etc/spamassassin/local.cf
Code:
use_bayes 1
bayes_auto_learn 1
bayes_auto_expire 0
bayes_path /var/lib/amavis/.spamassassin
20-debian_defaults
Code:
$sa_spam_subject_tag = '***SPAM*** ';
$sa_tag_level_deflt  = 2.0;  # add spam info headers if at, or above that level
$sa_tag2_level_deflt = 6.31; # add 'spam detected' headers at that level
$sa_kill_level_deflt = 6.31; # triggers spam evasive actions
$sa_dsn_cutoff_level = 10;   # spam level beyond which a DSN is not sent
...

Code:
root@intranet:/usr/local/postfix/mydomain.com/user@mydomain.com/cur# ls
1424025589.V801Ida6046M830986.intranet:2,ST  1424025594.M622625P2286V0000000000000801I0000000000DA605A_15.intranet,S=4819:2,S
root@intranet:/usr/local/postfix/mydomain/user@mydomain.com/cur# sa-learn --dbpath /var/lib/amavis/.spamassassin --ham *
Learned tokens from 1 message(s) (2 message(s) examined)
root@intranet:/usr/local/postfix/mydomain.com/user@mydomain.com/cur#

When sending again ... the email is SPAM again.

Last edited by daemoncesar; 02-15-2015 at 01:17 PM.
 
Old 02-16-2015, 02:49 PM   #2
daemoncesar
LQ Newbie
 
Registered: Feb 2015
Posts: 22

Original Poster
Rep: Reputation: Disabled
command "sa-learn --dbpath /var/lib/amavis/.spamassassin/bayes --ham --no-sync *"

Learned tokens from 5 message(s) (6 message(s) examined)

---
when the e- mail sending falls again in the spam box
 
Old 02-18-2015, 05:19 PM   #3
daemoncesar
LQ Newbie
 
Registered: Feb 2015
Posts: 22

Original Poster
Rep: Reputation: Disabled
The spamassassin not learn with amavis .
 
Old 02-19-2015, 03:08 AM   #4
daemoncesar
LQ Newbie
 
Registered: Feb 2015
Posts: 22

Original Poster
Rep: Reputation: Disabled
Code:
root@intranet:/usr/local/postfix/domain.com/user@domain.com/cur# sa-learn --username=amavis --ham --no-sync 1424336248.M774711P19603V0000000000000801I0000000000DA602A_12.intranet\,S\=4806\:2\,S
Learned tokens from 1 message(s) (1 message(s) examined)
root@intranet:/usr/local/postfix/domain.com/user@domain.com/cur# sa-learn --username=amavis --sync
bayes: synced databases from journal in 0 seconds: 145 unique entries (145 total entries)
Code:
Feb 19 07:03:55 intranet postfix/smtpd[2027]: connect from bay004-omc2s16.hotmail.com[65.54.190.91]
Feb 19 07:03:57 intranet postfix/smtpd[2027]: 330BFA0E786: client=bay004-omc2s16.hotmail.com[65.54.190.91]
Feb 19 07:03:57 intranet postfix/cleanup[2036]: 330BFA0E786: message-id=<BAY174-W500F87B89F83E56599D716A52D0@phx.gbl>
Feb 19 07:03:57 intranet postfix/qmgr[1535]: 330BFA0E786: from=<mailhotmail@hotmail.com>, size=4019, nrcpt=1 (queue active)
Feb 19 07:03:57 intranet postfix/smtpd[2027]: disconnect from bay004-omc2s16.hotmail.com[65.54.190.91]
Feb 19 07:04:01 intranet postfix/smtpd[2039]: connect from localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/smtpd[2039]: 5C39D23800E: client=localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/cleanup[2036]: 5C39D23800E: message-id=<BAY174-W500F87B89F83E56599D716A52D0@phx.gbl>
Feb 19 07:04:01 intranet postfix/smtpd[2039]: disconnect from localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 5C39D23800E: from=<mailhotmail@hotmail.com>, size=4911, nrcpt=1 (queue active)
Feb 19 07:04:01 intranet postfix/virtual[2040]: 5C39D23800E: to=<spam@mydomain>, relay=virtual, delay=0.01, delays=0/0/0/0, dsn=2.0.0, status=sent (delivered to maildir)
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 5C39D23800E: removed
Feb 19 07:04:01 intranet postfix/smtpd[2039]: connect from localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/smtpd[2039]: 5F70123800E: client=localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/cleanup[2036]: 5F70123800E: message-id=<SAcX99E0LfOKff@intranet.lua.myuser.net.br>
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 5F70123800E: from=<myuser@mydomain.com>, size=4112, nrcpt=1 (queue active)
Feb 19 07:04:01 intranet postfix/smtpd[2039]: disconnect from localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/virtual[2040]: 5F70123800E: to=<root@mydomain.com>, relay=virtual, delay=0.01, delays=0/0/0/0, dsn=2.0.0, status=sent (delivered to maildir)
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 5F70123800E: removed
Feb 19 07:04:01 intranet postfix/smtpd[2039]: connect from localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/smtpd[2039]: 6180D23800E: client=localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/cleanup[2036]: 6180D23800E: message-id=<BAY174-W500F87B89F83E56599D716A52D0@phx.gbl>
Feb 19 07:04:01 intranet postfix/smtpd[2039]: disconnect from localhost[127.0.0.1]
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 6180D23800E: from=<mailhotmail@hotmail.com>, size=4823, nrcpt=1 (queue active)
Feb 19 07:04:01 intranet postfix/virtual[2040]: 6180D23800E: to=<myuser+spam@mydomain>, relay=virtual, delay=0.01, delays=0.01/0/0/0, dsn=2.0.0, status=sent (delivered to maildir)
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 6180D23800E: removed
Feb 19 07:04:01 intranet amavis[1979]: (01979-04) Passed SPAM, [65.54.190.91] [65.54.190.124] <mailhotmail@hotmail.com> -> <myuser@mydomain.com>, quarantine: spam@mydomain, Message-ID: <BAY174-W500F87B89F83E56599D716A52D0@phx.gbl>, mail_id: cX99E0LfOKff, Hits: 1002.439, size: 4018, queued_as: 6180D23800E, 3615 ms
Feb 19 07:04:01 intranet postfix/smtp[2037]: 330BFA0E786: to=<myuser@mydomain.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=5.5, delays=1.9/0/0/3.6, dsn=2.0.0, status=sent (250 2.0.0 Ok, id=01979-04, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 6180D23800E)
Feb 19 07:04:01 intranet postfix/qmgr[1535]: 330BFA0E786: removed
The spamassain not learn. Always back to SPAM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[help] Amavisd-new + Spamassassin DarkSlayer Linux - Security 4 06-10-2011 07:06 AM
amavisd-new / spamassassin whitelist issue scheidel21 Linux - Server 5 10-19-2009 08:15 AM
amavisd / clamav, spamassassin problem 70mas Linux - Server 5 07-19-2007 08:42 PM
Do anyone use amavisd with spamassassin? combilli Linux - Software 1 11-13-2006 09:48 PM
Mystery (amavisd-new+spamassassin) stomach Linux - Software 1 02-22-2006 09:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:19 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration