Desired flow looks like: Dovecot ---------------------> Postfix --> Relay Server -? Dovecot <-- LMTP/LDA <-- Postfix <---------------------? Top part of that flow works fine - a message will get to the relay server and it will be send back to the postfix for a local delivery but then it will start to loop back to the relay server instead hand over to LMTP/LDA. For some reason Postfix doesn't know that abcd at localdomain.com is located on Dovecot and it will try to send it back to the relay server. I have the same problem explained here: https://serverfault.com/questions/1010325/postfix-via-relay-server-and-lmtp-configuration-for-incoming-delivery-to-local-m Thanks for any help! ~Adam ?On 4/1/20, 6:45 PM, "dovecot on behalf of Dauser Martin Johannes" <dovecot-bounces at dovecot.org on behalf of mdauser at cs.sbg.ac.at> wrote: On Dienstag, 31. M?rz 2020 21:14:26 CEST Adam Raszkiewicz wrote: > But then it loops again when get back to the postfix as an incoming message > (doesn't know that abcd at localdomain.com is located on that Dovecot) + > Is there any way to disable Dovecot LDA? I want to always send email via > postfix and relay server even it will be a local delivery within the Dovecot > server > >Thanks, >Adam Why should a disabled LDA or a relayhost help in this matter? Honestly, who is sending what to where anyway? I mean Dovecot is an IMAP-Server: It receives emails from Postfix and mailclients connect to Dovecot to get these mails. When a mailclient sends an email it connects to Postfix not to Dovecot, so a delivery "within Dovecot" isn't really happening. Dovecot's LDA has options to send (bounce) mails back to Postfix. I guess loops occur there? WHO doesn't know that abcd at localdomain.com is located on Dovecot -- Dovecot itself (= unknown recipient or perhaps permission problems while saving the mail) or Postfix (= no transport to Dovecot)? Martin
On Thu, 2 Apr 2020 13:18:14 +0000, Adam Raszkiewicz stated:>Desired flow looks like: > >Dovecot ---------------------> Postfix --> Relay Server -? >Dovecot <-- LMTP/LDA <-- Postfix <---------------------? > >Top part of that flow works fine - a message will get to the relay >server and it will be send back to the postfix for a local delivery >but then it will start to loop back to the relay server instead hand >over to LMTP/LDA. > >For some reason Postfix doesn't know that abcd at localdomain.com is >located on Dovecot and it will try to send it back to the relay >server. I have the same problem explained here: >https://serverfault.com/questions/1010325/postfix-via-relay-server-and-lmtp-configuration-for-incoming-delivery-to-local-m > >Thanks for any help! >~Adam > >?On 4/1/20, 6:45 PM, "dovecot on behalf of Dauser Martin Johannes" ><dovecot-bounces at dovecot.org on behalf of mdauser at cs.sbg.ac.at> wrote: > > On Dienstag, 31. M?rz 2020 21:14:26 CEST Adam Raszkiewicz wrote: > > But then it loops again when get back to the postfix as an > > incoming message (doesn't know that abcd at localdomain.com is > > located on that Dovecot) > + > > Is there any way to disable Dovecot LDA? I want to always send > > email via postfix and relay server even it will be a local > > delivery within the Dovecot server > > > >Thanks, > >Adam > > Why should a disabled LDA or a relayhost help in this matter? > Honestly, who is sending what to where anyway? > > I mean Dovecot is an IMAP-Server: It receives emails from Postfix > and mailclients connect to Dovecot to get these mails. When a > mailclient sends an email it connects to Postfix not to Dovecot, so a > delivery "within Dovecot" isn't really happening. Dovecot's LDA has > options to send (bounce) mails back to Postfix. I guess loops occur > there? > WHO doesn't know that abcd at localdomain.com is located on Dovecot > -- Dovecot itself (= unknown recipient or perhaps permission problems > while saving the mail) or Postfix (= no transport to Dovecot)? > > MartinThis question really belongs on the 'postfix' forum. Have you read <http://www.postfix.org/DEBUG_README.html> or better still, <http://www.postfix.org/DEBUG_README.html#mail>. The "postfinger" tool is the best way. -- Jerry -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 488 bytes Desc: OpenPGP digital signature URL: <https://dovecot.org/pipermail/dovecot/attachments/20200402/bd1711d8/attachment.sig>
On 02/04/2020 15:18, Adam Raszkiewicz wrote:> Desired flow looks like: > > Dovecot ---------------------> Postfix --> Relay Server -? > Dovecot <-- LMTP/LDA <-- Postfix <---------------------?This mail flow cannot work with one Postfix instance. Either Postfix knows that "localdomain.com" is local and should be delivered to the LDA, in which case it won't be forwarded to the relay server, or Postfix does not know that "localdomain.com" is a local address and therefor forwards it the relay server, but than it will do that anytime it sees "localdomain.com". Only possibility is to run two instances of Postfix. The real question is: Why do you want this mail flow? Where is the benefit in sending a local mail out to a relay server only to get it back and deliver it? Cheers, Juri
So there is no way to skip Postfix for incoming messages and go directly to LMTP/LDA but I need two instances of Postfix in that case? Regarding your second question - it is required to be complaint with Direct Trust. Thanks, Adam ?On 4/2/20, 3:07 PM, "dovecot on behalf of Juri Haberland" <dovecot-bounces at dovecot.org on behalf of juri at koschikode.com> wrote: On 02/04/2020 15:18, Adam Raszkiewicz wrote: > Desired flow looks like: > > Dovecot ---------------------> Postfix --> Relay Server -? > Dovecot <-- LMTP/LDA <-- Postfix <---------------------? This mail flow cannot work with one Postfix instance. Either Postfix knows that "localdomain.com" is local and should be delivered to the LDA, in which case it won't be forwarded to the relay server, or Postfix does not know that "localdomain.com" is a local address and therefor forwards it the relay server, but than it will do that anytime it sees "localdomain.com". Only possibility is to run two instances of Postfix. The real question is: Why do you want this mail flow? Where is the benefit in sending a local mail out to a relay server only to get it back and deliver it? Cheers, Juri