On 2010-09-12 05:53, Richard Chapman wrote:
Hi again Jasper..
I do appreciate your help - but have not solved the problem yet.
Please see below.
On 9/09/2010 11:58 PM, Jasper Jongmans wrote:
On 2010-09-09 17:29, Richard Chapman wrote:
[snip]
Sep 9 22:43:50 C5 postfix/local[9259]: B3D401D2231D:
to=<rchap...@c5.aardvark.com.au>, relay=local, delay=0.08,
delays=0.06/0.01/0/0.01, dsn=2.0.0, status=sent (forwarded as )
Above line means local(8) was instructed by something like aliases or
.forward to send to another address. The original message was
B3D401D2231D, the new is C37ED1D2232B.
OK. I have checked there are no .forward files in the relevant users
home directories. Is there anywhere else I should look? I am runnig
postfix, dovecot, centos 5.5. Hopefully this is not relevant - but I
think sendmail is still installed on this machine. I changed from
sendmail to postfix some time back.
I have disabled masquerading, but the problem remains.
I have some user aliases - but have done tests on users with no
obvious aliases - and emails to them are also rejected.
Do you have any other suggestions as to where to look for unwanted
aliases or forwards?
Edit master.cf and run local with -v for more verbose logging to find
out what makes local decide to forward the message. I still suspect
aliases or /home/richard/.forward are the culprit, run "postmap -q
rchapman /etc/aliases" and repeat with whatever that returns, also run
"cat /home/richard/.forward". You use procmail but local does not report
delivering to procmail, this suggests the rewrite occurs before
mailbox_command (check local man-page for delivery method precedence);
check your procmail recipes anyway, just in case. You are also using
virtual_alias_maps, check whether you really want this and that the
contents of the file are correct. You didn't specify
virtual_alias_domains so don't expect virtual aliases to work properly
if at all.
[snip]
The smtp-client connects to Google Apps and succesfully delivers the
message. Some forward at Google Apps leads to another connection to
your smtpd-server, which then rejects the email because it is
addressed to the wrong domain. You probably have had this detour for
a while, just didn't notice it before because your server accepted
the email in the second phase.
Yes. That is how I was interpreting it too. The forward at google apps
is intentional. I agree the problem is probably something lost in the
mists of time..:-)
Do you know whether masquerading could case this problem? I understood
that masquerading applied only to the sender address on outgoing email
- but I may be wrong. I
have certainly run tests with it disabled in main.cf - and I believe I
have restarted postix. Is there anything else I would need to do to
disable it properly? e.g. Would I need to run postmap on some file?
When exactly masquerading applies is a bit tricky, consult
masquerade_classes and masquerade_domains documentation. You described
earlier you want this server to receive only for c5.aardvark.com.au and
not aardvark.com.au. With your current settings mail from local users
will appear to come from aardvark.com.au and replies will go to Google
Apps, is this how you intend it to work? Consult
http://www.postfix.org/ADDRESS_REWRITING_README.html for other forms of
address rewriting.
Here is my postconf -n - in case you can see any clues in there. I
have also included /etc/aliases content - though it looks fairly
innocent to me.
You will see that at the time of the postconf - I have re-enabled
masquerading and domain receiving - because this is a live server - so
I revert it to a working state after each test.
[config]