[TriLUG] SpamAssassin as a daemon
jonc at nc.rr.com
Fri Jul 16 09:35:42 EDT 2004
On Fri, 2004-07-16 at 09:00, Brian Henning wrote:
> Hi Folks,
> This is probably something I should just google, but I'm at work so I need
> to look busier than "surfing the web".. (You know...doesn't matter what
> you're looking at; if you're not typing, you don't look busy...) So I
> figured if anyone felt like pointing me to a howto, or explaining in brief,
> I'd ask how to take advantage of the daemon portion of SpamAssassin. So far
> in my experience with spamassassin, I've used it as part of a procmail
> filter recipe (which doesn't seem to make use of spamd to me). What does
> the daemon give me, and why is it better (or simply is it better) than the
> procmail filter method? Further, if I want to have a non-sa-processed copy
> of all mail messages, does that preclude using spamd?
> Thanks as always,
The read me that comes with Spam Assassin is pretty good about
explaining how to use the daemon....
Craig Hughes has contributed "spamd", a daemonized
version of SpamAssassin, which runs persistently.
Using "spamc", a lightweight C client, this allows
an MTA to process large volumes of mail through
SpamAssassin without having to fork/exec a perl
interpreter for each one.
Which means that if you use SpamAssassin infrequently then don't worry
about it, but if you find your server running two or more simultaneous
SA instances (or you find it starting up the application over and over
again throughout the day) then you are better off running the daemon
=== From README.Spamd ===
Spamd is the workhorse of the spamc/spamd pair -- it loads an instance
of the spamassassin filters, and then listens as a daemon for incoming
requests to process messages....
Spamc is the client half of the pair. It should be used in place of
'spamassassin' in scripts to process mail. It will read the mail from
stdin, and spool it to its connection to spamd, then read the result
back and print it to stdout. Spamc has extremely low overhead in
loading, so it should be much faster to load than the whole spamassassin
program (and a perl VM).
So there you have it. Run "spamd" as a Daemon then substitute "spamc"
in your procmail (or where-ever you run "spamassassin).
More information about the TriLUG