[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: exim4 some config error causing error how to pinpoint



Liam O'Toole <liam.p.otoole@gmail.com> writes:

>> Mail never appears at HOST1 /var/spool/mail/user2
>>
>>
>
> Does user2 appear in the file /etc/aliases on HOST1? Is there a
No

> /home/user2/.forward file on that host? Either of those would cause mail
No

> Is there anything suspicious in the file /var/log/exim4/mainlog on
> HOST1?
Yes, there is this bit that seems to indicate that the message is
being processed by procmail.

dv.local.lan is HOST1  smarthost set to smtp.gmail.com
d2.local.lan is HOST2  smarthost set to HOST1

There is a user named `harry' on both hosts.

-------       -------       ---=---       -------       ------- 
2016-09-15 12:40:29 1bkZi9-0000Ne-MU <= harry@d2.local.lan H=(d2.local.lan) [192.168.1.17] P=esmtp S=608 id=E1bkZa7-0006Mb-CG@d2.local.lan
2016-09-15 12:40:31 1bkZi9-0000Ne-MU => harry <harry@dv> R=procmail T=procmail_pipe
2016-09-15 12:40:31 1bkZi9-0000Ne-MU Completed
2016-09-15 12:52:31 Start queue run: pid=1574
2016-09-15 12:52:31 End queue run: pid=1574
-------       -------       ---=---       -------       ------- 

There is a ~/.procmailrc for user2 but no specifc recipe that would
grab mail addressed to USER2@HOST1 (harry@dv).

However my .procmailrc has a final rule that catches anything not
already handled:

  :0
  post_ex.in

However the mail addressed user2@host1 is not going to that inbox (or
any other) either.

But dropping that mystery for the time being there seems to be
something bigger happening.

Since my previous post I have found that all those test messages to
user2 and user1 on HOST1 from HOST2 are being sent out to the
HOST1 smarthost and piling up as undeleverable on a gmail account.  My
smarthost is smtp.gmail.com

I guess that does make sense.  However I guess I just supposed that
somehow HOST1 would magically know not to try to send mail from other
lan hosts addressed to users on HOST1, out to the internet smarthost.

Maybe I need some other mechanism for that to happen?

To summarize the setup again very briefly... since it seems to be
getting more confusing ... at least to me.

HOST1 is setup to relay mail from its users to an internet smarthost
(smtp.gmail.com).

HOST2 is setup to relay mail from its users to HOST1 as its smarthost

When I try to send a message from USER@HOST2 to USER@HOST1, instead of
just delivering to USER@HOST1 it appears to be sending that message on
to the gmail smtp server.

The local lan is not a real FQDN so not suprising that the gmail
server cannot deliver it.... but how to prevent that local mail from
being sent to gmail server to start with?


Reply to: