Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

How to properly use sa-learn?

Discussion in 'E-mail Discussion' started by joako, Mar 16, 2015.

  1. joako

    joako Well-Known Member

    Joined:
    Aug 7, 2003
    Messages:
    112
    Likes Received:
    2
    Trophy Points:
    168
    cPanel Access Level:
    DataCenter Provider
    I have one account that gets too much spam. I enable sa-lean in the spamassassin configuration and then run it against the mail directories. The sa-learn shows that the minimum of 200 spam and 200 ham have been processed, but in the inbound email headers there is no indication that it is being used.

    What is the proper way to have sa-learn working for at least one account?
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,803
    Likes Received:
    1,898
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    16,475
    Likes Received:
    421
    Trophy Points:
    583
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    As commented on that link, the spam will keep coming, but good luck anyway.

    Google the email address that's getting all the spam, do you find it? If yes, so do email scrapers. Over and over and over again. And, they'll send new spam to it using new email addresses fully passable by spam filtering emails.

    Users need to learn to better obfuscate their email addresses on their own webpages, use secure contact forms, and should never ever post it anywhere if they can help it. But they don't.

    If you want to end the spam on that email account quick and easy? Kill the email account when it gets that bad. Or, see if the results found on searching for the email via google, can be scrubbed from the websites you found it on.

    Not the answer you were looking for, I'm sure. :rolleyes:
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. joako

    joako Well-Known Member

    Joined:
    Aug 7, 2003
    Messages:
    112
    Likes Received:
    2
    Trophy Points:
    168
    cPanel Access Level:
    DataCenter Provider
    When I read that documentation, it says to put in the config file:

    bayes_path /var/spamassassin/bayes_db/bayes

    But when I run sa-learn it creates /root/.spamassassin and in there is bayes_journal, bayes_seen, bayes_toks, and sa-compile.cache/. There is no bayes_db directory or any file called bayes.

    In /etc/mail/spamassassin/local.cf I already put:

    use_bayes 1
    bayes_auto_learn 1

    And I see for the users that have spamassassin enabled there is a ~/.spamassassin exactly like root's but still in the headers of received messages there is no indication that bayes is being used.
     
  5. joako

    joako Well-Known Member

    Joined:
    Aug 7, 2003
    Messages:
    112
    Likes Received:
    2
    Trophy Points:
    168
    cPanel Access Level:
    DataCenter Provider
    How can I edit the scores assigned to particular spamassassin rules on a global basis, and ensure these changes survive any spam rules updates? For e.g. this rule I would like for it to be assigned more points:

    1.7 RAZOR2_CHECK Listed in Razor2 (http://razor.sf.net/)
     
  6. kdean

    kdean Well-Known Member

    Joined:
    Oct 19, 2012
    Messages:
    285
    Likes Received:
    20
    Trophy Points:
    18
    Location:
    Orlando, FL
    cPanel Access Level:
    Root Administrator
    Edit /etc/mail/spamassassin/local.cf

    Add:
    score RAZOR2_CHECK #.#

    # - your score numbers

    Then restart spamd
    /scripts/restartsrv_spamd

    or restart Exim from WHM or with the following which will also restart spamd.
    /scripts/restartsrv_exim
     
  7. kdean

    kdean Well-Known Member

    Joined:
    Oct 19, 2012
    Messages:
    285
    Likes Received:
    20
    Trophy Points:
    18
    Location:
    Orlando, FL
    cPanel Access Level:
    Root Administrator
    After activating Bayes, you need to wait until after a few hundred SPAM and HAM emails are received before it actually starts scoring the emails. So you should see the bayes files being created for the accounts, but may need to wait some time before seeing the effect.
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice