You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Magnus Anderson <ma...@sonic2000.org> on 2006/11/12 12:59:33 UTC

CGPSA + MySQL, Userprefs Problems

Hi,

I'm having a problem with CGPSA and MySQL Userprefs settings.

For the record, this *was* working a few days ago when I was testing to
set it up, but somehow it stopped working suddenly. Just in time for me
to implement it into a working system.

Well, my problem is that it  only reacts on Global settings in the
Userprefs database. If I change $GLOBAL required_hits 7 to 8 it follows
nicely. But if I add a user or domain rule, it doesn't work.

It may be some clue that my mail server reports this...

Attempting to load domain configuration for sonic2000.org
Using root configuration for sonic2000.org
domain configuration already loaded, discard_threshold = 25
Attempting to load user configuration for magnus@sonic2000.org
Using domain configuration for magnus@sonic2000.org
Local address startail@sonic2000.org, account name magnus@sonic2000.org,
effective home
directory /var/CommuniGate/Settings/SpamAssassin
Using system default SpamAssassin settings for magnus@sonic2000.org
Processing CGP header line: \n
Finished processing CGP headers
Running SpamAssassin with domain sonic2000.org default settings for 1
address
SQL preferences in use, no state or user home directory
Identified non-spam (7.1/8.0) for <default> in 1.9 seconds

What makes me confused is that it now reports "for <default>" and not
"for magnus@sonic2000.org" as it used to do.

The only thing I have done is removing the state directories for
SpamAssassin in the CommuniGate folder. (account.web/.spamassassin)

My CGPSA Settings are these...
cgp_username = cgpsa-spamassassin-cli
cgp_password = xxxxxxxxxxx
use_cli = true
loop_prevention_header = X-TFF-CGPSA-Filter
debug = true
debug_level = 9
allow_user_prefs = true
allow_user_state = true
use_domain_prefs = true
allow_auto_whitelist = true
use_cgpsa = true
use_user_prefs = true
sql_user_prefs = true
use_user_state = true
use_auto_whitelist = true
sql_auto_whitelist = true

Hopefully someone can point me into the right direction for solving this


Re: CGPSA + MySQL, Userprefs Problems

Posted by Magnus Anderson <ma...@sonic2000.org>.
On Sun, 12 Nov 2006 12:59:33 +0100, Magnus Anderson wrote:

> Hi,
> 
> I'm having a problem with CGPSA and MySQL Userprefs settings.
> 
> For the record, this *was* working a few days ago when I was testing to
> set it up, but somehow it stopped working suddenly. Just in time for me
> to implement it into a working system.
> 
> Well, my problem is that it  only reacts on Global settings in the
> Userprefs database. If I change $GLOBAL required_hits 7 to 8 it follows
> nicely. But if I add a user or domain rule, it doesn't work.
> 
> It may be some clue that my mail server reports this...
> 
> Attempting to load domain configuration for sonic2000.org Using root
> configuration for sonic2000.org domain configuration already loaded,
> discard_threshold = 25 Attempting to load user configuration for
> magnus@sonic2000.org Using domain configuration for magnus@sonic2000.org
> Local address startail@sonic2000.org, account name magnus@sonic2000.org,
> effective home
> directory /var/CommuniGate/Settings/SpamAssassin Using system default
> SpamAssassin settings for magnus@sonic2000.org Processing CGP header
> line: \n
> Finished processing CGP headers
> Running SpamAssassin with domain sonic2000.org default settings for 1
> address
> SQL preferences in use, no state or user home directory Identified
> non-spam (7.1/8.0) for <default> in 1.9 seconds
> 
> What makes me confused is that it now reports "for <default>" and not
> "for magnus@sonic2000.org" as it used to do.
> 
> The only thing I have done is removing the state directories for
> SpamAssassin in the CommuniGate folder. (account.web/.spamassassin)
> 
> My CGPSA Settings are these...
> cgp_username = cgpsa-spamassassin-cli cgp_password = xxxxxxxxxxx
> use_cli = true
> loop_prevention_header = X-TFF-CGPSA-Filter debug = true
> debug_level = 9
> allow_user_prefs = true
> allow_user_state = true
> use_domain_prefs = true
> allow_auto_whitelist = true
> use_cgpsa = true
> use_user_prefs = true
> sql_user_prefs = true
> use_user_state = true
> use_auto_whitelist = true
> sql_auto_whitelist = true
> 
> Hopefully someone can point me into the right direction for solving this


I solved the problem with MySQL And the Userprefs file.

If there are no user_prefs file in the account.web/.spamassassin folder
the script thinks that the user doesn't have any preferences to load even
tough the user has preferences in the SQL DB.

To solve this I have to touch a empty file into each users
account.web/.spamassassin folder so it think it does need to run for that
user, and then it reports "Identified (spam/non-spam) (score) for
magnus@sonic2000.org" correctly.

This seems like a nasty bug, since there are no documents on this and I
was thinking I could remove all these files now when I was using SQL (so
it didn't read the wrong settings, like the ones that was once used in
these files).

Best Regards,
 Magnus