Loading ...
Sorry, an error occurred while loading the content.

Re: Deferred mail and transports and retries

Expand Messages
  • Wietse Venema
    ... According to RFC 5321 section 5.1, the sending host should try at least two delivery addresses. Quote: When the lookup succeeds, the mapping can result in
    Message 1 of 10 , Jul 25, 2013
    • 0 Attachment
      Abhijeet Rastogi:
      > Hi Wietse,
      >
      > Thanks for you reply. I may be wrong but I just know what I read in
      > http://tools.ietf.org/html/rfc5321#section-4.5.4
      >
      > > The sender MUST delay retrying a particular destination after one
      > > attempt has failed. In general, the retry interval SHOULD be at

      According to RFC 5321 section 5.1, the sending host should try at
      least two delivery addresses.

      Quote:

      When the lookup succeeds, the mapping can result in a list of
      alternative delivery addresses rather than a single address,
      because of multiple MX records, multihoming, or both. To provide
      reliable mail transmission, the SMTP client MUST be able to try
      (and retry) each of the relevant addresses in this list in order,
      until a delivery attempt succeeds. However, there MAY also be
      a configurable limit on the number of alternate addresses that
      can be tried. In any case, the SMTP client SHOULD try at least
      two addresses.

      If you believe that Postfix should wait between the attempts to
      connect to the first and the second MX address, then you are in
      error.

      Wietse
    • Peer Heinlein
      ... Because that s best Postfix can do. Because Postfix SHOULD do that: *) Because if on MX is down, the second one could/should be up and running, so why
      Message 2 of 10 , Jul 25, 2013
      • 0 Attachment
        Am 25.07.2013 09:52, schrieb Abhijeet Rastogi:


        > The issue is, why does postfix retry the second time instantly (within 1
        > sec)? Shouldn't postfix wait till the next deferred queue scan happens?

        Because that's best Postfix can do. Because Postfix SHOULD do that:

        *) Because if on MX is down, the second one could/should be up and
        running, so why shouldn't Postfix use it
        *) Because Postfix isn't interested in wasting resources and storing
        deliverable e-mails in the deferred queue
        *) Because the sender wants to have delivered his e-mail fast without
        unnecessary delays
        *) Because the recupient wants to receive his e-mails quickly without
        unnecessary delays

        If you believe that deferring e-mails and wasting time is helpful, then use

        smtp_mx_address_limit = 1
        smtp_mx_session_limit = 1

        but don't complain about delays.


        Peer



        --
        Heinlein Support GmbH
        Schwedter Str. 8/9b, 10119 Berlin

        http://www.heinlein-support.de

        Tel: 030 / 405051-42
        Fax: 030 / 405051-19

        Zwangsangaben lt. §35a GmbHG: HRB 93818 B / Amtsgericht
        Berlin-Charlottenburg,
        Geschäftsführer: Peer Heinlein -- Sitz: Berlin
      • Abhijeet Rastogi
        Hi Wietse, This helps. Half reading is always bad. This clears everything about my doubt. One other thing still remains. I ve multiple smtp services defined
        Message 3 of 10 , Jul 25, 2013
        • 0 Attachment
          Hi Wietse,

          This helps. Half reading is always bad. This clears everything about my doubt.

          One other thing still remains. I've multiple smtp services defined like this. (in master.cf, to use different IPs, selected randomly)

          ob-smtp1   unix    -       -       n       -       -     smtp
            -o smtp_bind_address=1.2.3.4
            -o syslog_name=postfix-smtp1
          ob-smtp2   unix    -       -       n       -       -     smtp
            -o smtp_bind_address=5.6.7.8
            -o syslog_name=postfix-smtp2

          I suppose that if a message delivered via one of the transport and deferred, it'll always be tried via the same "smtp service". Is there a possibility where I can change the smtp service while retrying for a already deferred mail?

          On Thu, Jul 25, 2013 at 6:06 PM, Wietse Venema <wietse@...> wrote:
          Abhijeet Rastogi:
          > Hi Wietse,
          >
          > Thanks for you reply. I may be wrong but I just know what I read in
          > http://tools.ietf.org/html/rfc5321#section-4.5.4
          >
          > >  The sender MUST delay retrying a particular destination after one
          > >  attempt has failed.  In general, the retry interval SHOULD be at

          According to RFC 5321 section 5.1, the sending host should try at
          least two delivery addresses.

          Quote:

             When the lookup succeeds, the mapping can result in a list of
             alternative delivery addresses rather than a single address,
             because of multiple MX records, multihoming, or both.  To provide
             reliable mail transmission, the SMTP client MUST be able to try
             (and retry) each of the relevant addresses in this list in order,
             until a delivery attempt succeeds.  However, there MAY also be
             a configurable limit on the number of alternate addresses that
             can be tried.  In any case, the SMTP client SHOULD try at least
             two addresses.

          If you believe that Postfix should wait between the attempts to
          connect to the first and the second MX address, then you are in
          error.

                  Wietse



          --
          Regards,
          Abhijeet Rastogi (shadyabhi)
          http://blog.abhijeetr.com
        • Wietse Venema
          ... You can specify an alternate MTA (with smtp_fallback_relay) for delayed mail. There is no feature to specify an alternate delivery agent for delayed mail.
          Message 4 of 10 , Jul 26, 2013
          • 0 Attachment
            Abhijeet Rastogi:
            > Hi Wietse,
            >
            > This helps. Half reading is always bad. This clears everything about my
            > doubt.
            >
            > One other thing still remains. I've multiple smtp services defined like
            > this. (in master.cf, to use different IPs, selected randomly)
            >
            > ob-smtp1 unix - - n - - smtp
            > -o smtp_bind_address=1.2.3.4
            > -o syslog_name=postfix-smtp1
            > ob-smtp2 unix - - n - - smtp
            > -o smtp_bind_address=5.6.7.8
            > -o syslog_name=postfix-smtp2
            >
            > I suppose that if a message delivered via one of the transport and
            > deferred, it'll always be tried via the same "smtp service". Is there a
            > possibility where I can change the smtp service while retrying for a
            > already deferred mail?

            You can specify an alternate MTA (with smtp_fallback_relay) for
            delayed mail. There is no feature to specify an alternate delivery
            agent for delayed mail.

            The example looks like an attempt to circumvent Yahoo etc. rate
            limits per client IP address. I don't have to make that "easy"
            with Postfix.

            Wietse
          • Abhijeet Rastogi
            You can specify an alternate MTA (with smtp_fallback_relay) for ... Hmm, I was aware of that thing. I ve not used this feature but it s definitely worth
            Message 5 of 10 , Jul 26, 2013
            • 0 Attachment
              You can specify an alternate MTA (with smtp_fallback_relay) for
              delayed mail.  There is no feature to specify an alternate delivery
              agent for delayed mail.


              Hmm, I was aware of that thing.  I've not used this feature but it's definitely worth trying.

              The example looks like an attempt to circumvent Yahoo etc. rate
              limits per client IP address.  I don't have to make that "easy"
              with Postfix.

              It's not about me trying to do spam. I'm part of a hosting company and sometimes our IPs get blocked temporarily when our outbound spam system stops performing for some odd reason.

              Thanks for the help.
               

                      Wietse



              --
              Regards,
              Abhijeet Rastogi (shadyabhi)
              http://blog.abhijeetr.com
            Your message has been successfully submitted and would be delivered to recipients shortly.