1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

When is spamtrain executed?

Discussion in 'Plesk 10.x for Linux Issues, Fixes, How-To' started by Flachzange, Mar 28, 2012.

  1. Flachzange

    Flachzange Basic Pleskian

    26
     
    Joined:
    Jul 1, 2009
    Messages:
    71
    Likes Received:
    0
    Hi Igor and rest.

    Latest Plesk Version uses spamtrain tool to train spam messages being stored in spam folders. Unfortunately this tool is documented less and without modifications you don't even know whether it is working not (no log output). Now I am wondering when (respectively where) spamtrain is called. I assumed it is some cron job, but I couldn't find anything in the usual cron folders cron.* and crontab.

    I know that is called in the middle of the night but that's all.

    Thanks for your help!

    Christoph
     
  2. Matt.D

    Matt.D Guest

    0
     
    I am also trying to find if and/or when its run.

    And like many (based on what I see in the forums), would like to see SPAMTRAIN delete the emails from the SPAM folder once it has kearnt from them.
     
  3. nforde

    nforde Basic Pleskian

    23
    90%
    Joined:
    Dec 11, 2004
    Messages:
    60
    Likes Received:
    0
    I believe spamtrain is executed in this way -

    You'll have a file at /etc/crontab that has something like this -

    # run-parts
    01 * * * * root run-parts /etc/cron.hourly
    02 4 * * * root run-parts /etc/cron.daily
    22 4 * * 0 root run-parts /etc/cron.weekly
    42 4 1 * * root run-parts /etc/cron.monthly

    As you can see, it calls the /etc/cron.daily/ folder each day, which contains this file - /etc/cron.daily/50plesk-daily

    That executes /usr/local/psa/admin/plib/DailyMaintainance/script.php

    That script executes most (if not all) of the other php scripts in /usr/local/psa/admin/plib/DailyMaintainance/

    In particular, I believe it executes /usr/local/psa/admin/plib/DailyMaintainance/execute-spamtrain.php

    Which then executes /usr/local/psa/admin/sbin/spamtrain

    The other scripts it calls are related to things like hosting space stats, data transfer stats, awstats stats, webalizer stats, etc... (spam training gets called AFTER each of these things I've just mentioned).
     
Loading...