Hello all.. Novice SA Admin here (well, none of my users complain - wait..
I have none, just me). I recently read something that says sa-learn is
learned for the user who runs sa-learn. I've always run sa-learn as root.
Is there a easy way to copy the contents of what's been learned from root
to my user?
I did read through the sa-learn doc, but maybe the way I'm wording it
isn't how it's worded in the docs.
If it's saved in an SQL database, I imagine you could do a simple UPDATE
query to change the username, like...
UPDATE bayes_vars SET username='username' WHERE username='root';
(Apologies if that's MySQL-specific. It's what I use.)
If you're not using SQL, you could follow the instructions to do a backup
and restore of the database, which would go something like this...
sa-learn --backup > /tmp/file.txt
sa-learn -u username --restore=/tmp/file.txt
Then, in the future, just add "-u username" to your sa-learn command line to
learn as the desired username rather than root.