Old pages no longer current in 2021
- Old pages no longer current in 2021
- issues ⇒
Updated information at: Classic Linux.
Also please see: https://discourse.rahul.net/.
This page is obsolete, but is kept available for reference.
If you were previously using a privately-installed version of spamassassin, you should follow the recommendations below. NOTE: If you have any privately-installed SpamAssassin programs in your execution PATH, you may encounter problems. Before proceeding, either remove these privately-installed SpamAssassin programs or make sure they are at the end of your execution PATH, not near the beginning, so the system-supplied SpamAssassin programs are always executed.
You probably already have a
user_prefs file in your
.spamassassin directory. Manually combine your personal settings in this file with the global defaults contained in the file:
Your previous SpamAssassin installation may already have collected some Bayesian tokens. If so, they will be in your .spamassassin directory in files whose names match “
bayes*”, such as:
bayes_journal bayes_seen bayes_toks
You can import these into the new SpamAssassin's central database.
sa-learn at least once with the
–ham option (as described in the Bayesian Filtering section on the page spamassassin_to_identify_spam), so that the central database is correctly initialized for you. Otherwise the steps below may fail.
Then cd into your
.spamassassin directory and use the following commands:
% sa-learn --siteconfigpath=/ --backup > data.txt % sa-learn --restore data.txt
sa-learn command above will export your current Bayesian data into a file called “
data.txt”. Any error message of the form “
bayes: bayes db version 2 is not able to be used, aborting! …” can be safely ignored.
sa-learn command will import data from “
data.txt” into the central database.
sa-learn commands above can take a while, depending on the size of your existing Bayesian data.
–restore step above, you can check the size of the imported data with:
% sa-learn --dump magic
Look at the “
nham'”' and “nspam
” values to get a count of non-spam and spam tokens respectively in the database.
After the import has been done, you can delete the “bayes*
” files in your .spamassassin'' directory thus:
% rm bayes*