Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

i'm using postfix, amavis-new, clamav and spamassassin.

Now I'm thinking of having dspam together, and training dspam from data collected by spamassassin. Any possible way to forward mail classified as spam by spamassassin to dspam either directly from spamassassin or from amavis-new?


share|improve this question

You could write a script that crawl the users "Spam" folder and train dspam from those mails.

You could also filter mail from amavisd-new with something like:

(blow is just an example stub config, untested)


/^<xxx-spam-regex-subject?,to?>.*$/ FILTER dspam:dspam
/./ OK


dspam                 unix    -       n       n       -       -    pipe \
flags=Ru user=dspam argv=/usr/bin/dspam --client --deliver=innocent,spam --user \
${recipient} --mail-from=${sender}


check_client_access pcre:/etc/postfix/dspam_filter_access
dspam_destination_recipient_limit = 1
share|improve this answer

At startup, modern amavisd-new version look for a number of binaries in $PATH, including the dspam executable. If this one is found, dspam will automatically be trained with the results of all other spam checks configured in amavisd-new.

The only downside is: All mail content is learned with only one user id (same as amavisd-new's SA integration).

And, totally OT: dspam is simply not worth the hassle.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.