You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spamassassin.apache.org by du...@apache.org on 2005/08/18 08:45:57 UTC

svn commit: r233291 - /spamassassin/trunk/sa-learn.raw

Author: duncf
Date: Wed Aug 17 23:45:54 2005
New Revision: 233291

URL: http://svn.apache.org/viewcvs?rev=233291&view=rev
Log:
Document the procedure for migrating back-ends. This needs to be
documented somewhere in the distribution, not just the wiki, though
this may not be the ideal spot.

Modified:
    spamassassin/trunk/sa-learn.raw

Modified: spamassassin/trunk/sa-learn.raw
URL: http://svn.apache.org/viewcvs/spamassassin/trunk/sa-learn.raw?rev=233291&r1=233290&r2=233291&view=diff
==============================================================================
--- spamassassin/trunk/sa-learn.raw (original)
+++ spamassassin/trunk/sa-learn.raw Wed Aug 17 23:45:54 2005
@@ -786,6 +786,55 @@
 
 =back
 
+=head1 MIGRATION
+
+There are now multiple backend storage modules available for storing
+user's bayesian data. As such you might want to migrate from one
+backend to another. Here is a simple procedure for migrating from one
+backend to another.
+
+Note that if you have individual user databases you will have to
+perform a similar procedure for each one of them.
+
+=over 4
+
+=item sa-learn --sync
+
+This will sync any outstanding journal entries
+
+=item sa-learn --backup > backup.txt
+
+This will save all your Bayes data to a plain text file.
+
+=item sa-learn --clear
+
+This is optional, but good to do to clear out the old database.
+
+=item Repeat!
+
+At this point, if you have multiple databases, you should perform the
+procedure above for each of them. (i.e. each user's database needs to
+be backed up before continuing.)
+
+=item Switch backends
+
+Once you have backed up all databases you can update your
+configuration for the new database backend. This will involve at least
+the bayes_store_module config option and may involve some additional
+config options depending on what is required by the module. (For
+example, you may need to configure an SQL database.)
+
+=item sa-learn --restore backup.txt
+
+Again, you need to do this for every database.
+
+=back
+
+If you are migrating to SQL you can make use of the -u <username>
+option in sa-learn to populate each user's database. Otherwise, you
+must run sa-learn as the user who database you are restoring.
+
+
 =head1 INTRODUCTION TO BAYESIAN FILTERING
 
 (Thanks to Michael Bell for this section!)