Hi everyone,
I had a lot of problems recently with mail being identified as spam.
This is still the case. Around 20% of spam is still getting through,
but i'm working through the problem.
I noticed that as per the amavis documentation:
"No spam-related headers inserted? Here are some reasons:
@local_domains_acl is not correctly set. These headers are only
inserted for recipients matching @local_domains_acl lookup (or
%local_domains or $local_domains_re or field 'local' in SQL lookups);"
I was only using my local server domain name, and not any of my
virtual hosts names, so none of my virtual hostname-destined emails
had any Spam related headers, only X-Virus.
I looked for a solution for looking up my MySQL based list of domains
(virtual hosts) which I have had in place for some years now. After
looking around a bit, this is what I came up with:
@lookup_sql_dsn = ( ['DBI:mysql:database=[name of my db here];host=[my
servers hostname here];port=3306', 'root', '[mysql user pass here]']
);
$sql_select_policy = 'SELECT "Y" as local FROM domains WHERE
CONCAT("@",domain_name) IN (%k)';
which pulls back a 'Y' if the domain matches the domain name in "To:"
against my virtual domains list in my mysql table. I verified this in
the mysql log.
However, I get the following error whenever a virtual domain is matched :
Feb 15 22:37:24 xbolt amavis[3524]: (03524-02)
lookup_sql_field(spam_tag2_level) (WARNING: no such field in the SQL
table), "[EMAIL PROTECTED]" matches, result=undef
I have searched high and low on google and in the manuals and I can't
place exactly what this means. I am unsure as to whether it is
actually causing a problem or not.
Here is what the query looks like to MySQL in the log:
SELECT "Y" as local FROM domains WHERE CONCAT("@",domain_name) IN
([EMAIL PROTECTED]','@virtualdomain.com','@.')
Please let me know if you want any further config - any help is
greatly appreciated!
With thanks,
Ali Ross
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
AMaViS-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/