MailScanner SPAM Forward & Postfix Problem

Drew Marshall drew at THEMARSHALLS.CO.UK
Fri Apr 8 13:23:50 IST 2005


    [ The following text is in the "iso-8859-1" character set. ]
    [ Your display is set for the "US-ASCII" character set.  ]
    [ Some characters may be displayed incorrectly. ]

Kennedy Clark said:
> On Apr 8, 2005 3:50 AM, Drew Marshall <drew at themarshalls.co.uk> wrote:
>> If the account you are forwarding to is a local account (Which it would
>> be
>> if it has a shell account) then you don't need to do anything other than
>> specify it in MailScanner. I have assumed that you have defined
>> mydomains
>> = mydomain.com (So Postfix knows it's local), then remove spamstuff from
>> your aliases file and that should work.
>>
>
> Yeah, this makes perfect sense... which is why this is driving me nuts
> (this is what I tried first).  I have "mydomain = mydomain.com" in
> main.conf, so it should know it's local.  I then remove  all mention
> of spamstuff from both /etc/postfix/aliases and
> /etc/postfix/virtual_alias (and obviously rebuild both .db files).  I
> have then tried several options in MailScanner.conf (I'm using the
> "Non Spam Actions" here because I can test it right away vs. having to
> wait for spam to come in -- once I get it working I'll obviously
> remove this and put it in as a spam action):
>    Non Spam Actions = deliver forward spamstuff
>    Non Spam Actions = deliver forward spamstuff at mydomain.com
>    Non Spam Actions = deliver forward spamstuff at localhost.mydomain.com
>    Non Spam Actions = deliver forward spamstuff at svr.mydomain.com
> I try every one of these (one at a time, of course) and I get the same
> result:
>
> Apr  8 05:43:18 svr postfix/error[19471]: 5CF4C73C651:
> to=<spamstuff at mydomain.com>, orig_to=<unknown>, relay=none, delay=3,
> status=deferred (SOFT BOUNCE - user unknown in virtual alias table)
>
> No matter what I do, it always says the users isn't in the virtual
> table.  I have found this to be true before I installed MailScanner...
> it's like it ignores the /etc/postfix/aliases.  BTW, I believe I do
> have both aliases and virtial_alias correctly specified in my postfix
> main.cf -- here are thre relevant bits:
>   mydestination = $myhostname, localhost.$mydomain
>   virtual_alias_domains = mydomain.com, myotherdomain.com

OK here is the first problem. You _don't_ have mydomain listed under
mydestination. Move it from virtual_alias_domains to mydestination. (This
assumes that you deliver mail to local mailboxes, which I believe is true
but you haven't confirmed).

>   virtual_alias_maps = hash:/etc/postfix/virtual_alias

Again with the same assumption, move any reference to mydomain out of
virtual_alias and any aliases to _real_ accounts into /etc/postfix/aliases

>   alias_maps = hash:/etc/postfix/aliases
> Have I got something else hosed?  Is using the virtual_alias_maps
> supposed to complete shut off the normal aliases file?

No, the idea of virtual_alias_maps is that it translates virtual aliases
to either virtual mailboxes or other addresses for example,
sales at virtdomain.com becomes salesman at internal.virtdomain.com (So you can
run MailScanner as a gateway in front of Exchange or Notes for example).
For anything local, you must use proper shell accounts and the aliases
table (Where domains are not listed). Some times users don't want/ need
shell accounts so you can use virtual_mailbox_domains for these, this
needs more setting up to do correctly, but it's not too tricky. Speak to
me off list if you want help with that).

> (Actually, I know it's still there in some way [it still works for the
"devnull:
> /dev/null"  entry I have in /etc/postfix/aliases], but all I can't get
> it to work for normal email addresses [local or remote]).
>
> It's driving me crazy!  Am I doing something dumb here?  Maybe I'm the
> one who needs coffee. :-)

Drew



--
In line with our policy, this message has
been scanned for viruses and dangerous
content by MailScanner, and is believed to be clean.
www.themarshalls.co.uk/policy

------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
'leave mailscanner' in the body of the email.
Before posting, read the MAQ (http://www.mailscanner.biz/maq/) and
the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).

Support MailScanner development - buy the book off the website!




More information about the MailScanner mailing list