You can manually train SpamAssassin to work with all mail accounts on
the server from the command line using the sa-learn
utility that is
a part of SpamAssassin.
To train SpamAssassin to work with all mail names on the server:
-
Prepare samples of spam and ham (non-spam) messages. The recommended
number is several thousand of each. -
Store spam and ham messages in two different folders for each
mailbox. -
Train SpamAssassin to work with one mailbox using the messages from
these folders:# sa-learn --spam </path/to/spam/folder> # sa-learn --ham </path/to/ham/folder>
where
</path/to/spam/folder>
and</path/to/ham/folder>
should
be replaced by the paths to the folders with spam and ham messages of
the corresponding mailbox. -
Repeat this command for every mailbox on the server.
Find more information about using the sa-learn
utility in the
SpamAssassin
documentation.