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

about special relay due to earthquake from Taiwan

Expand Messages
  • Dogz
    Hi, We meet the big problem in sending out email to China, Hong Kong and some of Asia domains. Telecommunications around Asia were severely disrupted on
    Message 1 of 11 , Dec 28, 2006
    • 0 Attachment
      Hi,

      We meet the big problem in sending out email to China, Hong Kong and some of Asia domains. Telecommunications around Asia were severely disrupted on Wednesday after earthquakes off Taiwan damaged undersea cables, slowing Internet services and so on. We are trying to relay some mail server to solve this problems.

      I know I can use transport and relay_domains and relay_recipient_maps maps, but I have another questions, would you please give me a hand?

      One of ISP provided the email address for me to forward some domains messages, and then they will send out these messages automatically. This seems to be like relay_domains function, but I have checkd the conf(5) in postfix web site, don't know how to do that.

      for example, I assume thess special email address called "dogz.hk@..." for relaying to Hong Kong and "dogz.cn@... " for relaying to China. If my colleagues want to send out the email to Hong Kong or China and so on ... My server will forward these message to those special email address.

      But how can I set up these to make sure my mail server to decide which mails should forward to dogz.hk@... or dogz.cn@... ?

      another question is how they handle that messages to send out the mail to right destination ?  If I need to create like this for another office to use.

      Any suggestions  will  appreciate.

      Thank you in advance.
      --
      Best Regards,
      Dogz
    • Magnus Bäck
      On Friday, December 29, 2006 at 03:41 CET, ... That s easy enough with a couple of virtual aliases, but you will lose the envelope information. How is the site
      Message 2 of 11 , Dec 29, 2006
      • 0 Attachment
        On Friday, December 29, 2006 at 03:41 CET,
        Dogz <kusoit@...> wrote:

        > We meet the big problem in sending out email to China, Hong Kong and
        > some of Asia domains. Telecommunications around Asia were severely
        > disrupted on Wednesday after earthquakes off Taiwan damaged undersea
        > cables, slowing Internet services and so on. We are trying to relay
        > some mail server to solve this problems.
        >
        > I know I can use transport and relay_domains and relay_recipient_maps
        > maps, but I have another questions, would you please give me a hand?
        >
        > One of ISP provided the email address for me to forward some domains
        > messages, and then they will send out these messages automatically.
        > This seems to be like relay_domains function, but I have checkd the
        > conf(5) in postfix web site, don't know how to do that.
        >
        > for example, I assume thess special email address called "
        > dogz.hk@..." for relaying to Hong Kong and
        > "dogz.cn@..." for relaying to China. If my colleagues want to
        > send out the email to Hong Kong or China and so on ... My server will
        > forward these message to those special email address.

        That's easy enough with a couple of virtual aliases, but you will lose
        the envelope information. How is the site managing example.com going to
        know which recipients you really wanted to reach?

        > But how can I set up these to make sure my mail server to decide which
        > mails should forward to dogz.hk@... or dogz.cn@... ?

        If you know what domains to route where it's easy with the transport
        table.

        cn dogz.cn@...
        hk dogz.hk@...
        known-chinese-domain.example.com dogs.cn@...

        > another question is how they handle that messages to send out the mail
        > to right destination ? If I need to create like this for another
        > office to use.

        That's the problem. As I said above, the people that manage example.com
        cannot know the original recipient of the messages.

        What they need to do is provide a server that relays messages for
        certain domains via other routes than usual. Then you can use the
        transport table to route the messages to their server while preserving
        the envelope information.

        --
        Magnus Bäck
        magnus@...
      • Dogz
        Hi Magnus, Thank you for your soon reply. I hope I did not misunderstand what you said. I add the following line into config files: # vi /etc/postfix/main.cf
        Message 3 of 11 , Dec 29, 2006
        • 0 Attachment
          Hi Magnus,

          Thank you for your soon reply.
          I hope I did not misunderstand what you said.

          I add the following line into config files:

          # vi /etc/postfix/main.cf
          ...
          myhostname = mail.TTTT.com
          relay_domains = pcre:/etc/postfix/relay_domains
          transport_maps= pcre:/etc/postfix/transport

          # vi /etc/postfix/relay_domains
          /test\.com/           ok

          # vi /etc/postfix/transport
          /test\.com/                    dogz@...

          And reload the postfix service

          I sent the email(reciepent's email address is dogz@... ) via relay this server, but it can't work it out, the log is as following

          Dec 29 11:46:16 linux postfix/qmgr[4228]: warning: connect to transport dogz@...: No such file or directory

          Would you please point out where I was wrong ?
          Thank you in advance.

          2006/12/29, Magnus Bäck <magnus@...>:
          On Friday, December 29, 2006 at 03:41 CET,
               Dogz <kusoit@...> wrote:

          > We meet the big problem in sending out email to China, Hong Kong and
          > some of Asia domains. Telecommunications around Asia were severely
          > disrupted on Wednesday after earthquakes off Taiwan damaged undersea
          > cables, slowing Internet services and so on. We are trying to relay
          > some mail server to solve this problems.
          >
          > I know I can use transport and relay_domains and relay_recipient_maps
          > maps, but I have another questions, would you please give me a hand?
          >
          > One of ISP provided the email address for me to forward some domains
          > messages, and then they will send out these messages automatically.
          > This seems to be like relay_domains function, but I have checkd the
          > conf(5) in postfix web site, don't know how to do that.
          >
          > for example, I assume thess special email address called "
          > dogz.hk@..." for relaying to Hong Kong and
          > "dogz.cn@..." for relaying to China. If my colleagues want to
          > send out the email to Hong Kong or China and so on ... My server will
          > forward these message to those special email address.

          That's easy enough with a couple of virtual aliases, but you will lose
          the envelope information. How is the site managing example.com going to
          know which recipients you really wanted to reach?

          > But how can I set up these to make sure my mail server to decide which
          > mails should forward to dogz.hk@... or dogz.cn@... ?

          If you know what domains to route where it's easy with the transport
          table.

          cn                                    dogz.cn@...
          hk                                    dogz.hk@...
          known-chinese-domain.example.com      dogs.cn@...

          > another question is how they handle that messages to send out the mail
          > to right destination ?  If I need to create like this for another
          > office to use.

          That's the problem. As I said above, the people that manage example.com
          cannot know the original recipient of the messages.

          What they need to do is provide a server that relays messages for
          certain domains via other routes than usual. Then you can use the
          transport table to route the messages to their server while preserving
          the envelope information.

          --
          Magnus Bäck
          magnus@...



          --
          Best Regards,
          Dogz
        • Bryan Irvine
          ... Anybody know if the ancient percent hack still works? Seems like the perfect use for it here. ie: dogz%example.com@the.hk.server
          Message 4 of 11 , Dec 29, 2006
          • 0 Attachment
            On 12/28/06, Dogz <kusoit@...> wrote:
            > Hi,
            >
            > We meet the big problem in sending out email to China, Hong Kong and some of
            > Asia domains. Telecommunications around Asia were severely disrupted on
            > Wednesday after earthquakes off Taiwan damaged undersea cables, slowing
            > Internet services and so on. We are trying to relay some mail server to
            > solve this problems.

            Anybody know if the ancient 'percent hack' still works? Seems like
            the perfect use for it here.

            ie: dogz%example.com@...
          • mouss
            ... do not top post. ... Are you from Moniker Privacy Services? ... so you relay mail for test.com.anydomain.example ? why use pcre when hash is enough.
            Message 5 of 11 , Dec 30, 2006
            • 0 Attachment
              Dogz wrote:
              > Hi Magnus,
              >
              > Thank you for your soon reply.
              > I hope I did not misunderstand what you said.
              >

              do not top post.

              > I add the following line into config files:
              >
              > # vi /etc/postfix/main.cf
              > ...
              > myhostname = mail.TTTT.com

              Are you from Moniker Privacy Services?


              > relay_domains = pcre:/etc/postfix/relay_domains
              > transport_maps= pcre:/etc/postfix/transport
              >
              > # vi /etc/postfix/relay_domains
              > /test\.com/ ok

              so you relay mail for test.com.anydomain.example ?

              why use pcre when hash is enough.
              test.example ok
              .test.example ok

              the .test.com entry is subject to parent_domain_matches_subdomain setting.
              >
              > # vi /etc/postfix/transport
              > /test\.com/ dogz@...
              >

              no. this is a (risky) virtual alias entry. (it's risky because it breaks
              recipient validation).


              for transports, use something like (hash, not pcre here):

              test.example smtp:[earthquake.relay.example]:587

              earthquake.relay.example must accept to relay mail for test.example. In
              the example above, they allow you do that by using port 587 on their relay.

              > And reload the postfix service
              >
              > I sent the email(reciepent's email address is dogz@... ) via
              > relay this
              > server, but it can't work it out, the log is as following
              >
              > Dec 29 11:46:16 linux postfix/qmgr[4228]: warning: connect to transport
              > dogz@...: No such file or directory
              >
              > Would you please point out where I was wrong ?

              you are mixing transports and (virtual) aliases.
            • Dogz
              Hi, Mouss, ... I don t get it, I don t understand what you meant. I followed what Magnus said to do these following steps, I think you may not read his post.
              Message 6 of 11 , Dec 30, 2006
              • 0 Attachment
                Hi, Mouss,



                2006/12/30, mouss <usebsd@...>:
                Dogz wrote:
                > Hi Magnus,
                >
                > Thank you for your soon reply.
                > I hope I did not misunderstand what you said.

                >>do not top post.

                I don't get it, I don't understand what you meant.

                I followed what Magnus said to do these following steps, I think you may not read his post.

                >> for example, I assume thess special email address called "
                >> dogz.hk@..." for relaying to Hong Kong and
                >> "dogz.cn@..." for relaying to China. If my colleagues want to
                >> send out the email to Hong Kong or China and so on ... My server will
                >> forward these message to those special email address.

                >That's easy enough with a couple of virtual aliases, but you will lose
                >the envelope information. How is the site managing example.com going to
                >know which recipients you really wanted to reach?

                >> But how can I set up these to make sure my mail server to decide which
                >> mails should forward to dogz.hk@... or dogz.cn@... ?

                >If you know what domains to route where it's easy with the transport table.

                >cn                                    dogz.cn@...
                >hk                                     dogz.hk@...
                >known-chinese-domain.example.com       dogs.cn@...

                In this case, we found the one of ISP can help us to relay it to send out emails to China, Hong Kong and so on. He just give us one email account to relay. Therefore we need to forward some domains belonged to China NIC, Hong Kong NIc and so on to this ISP, so that we can send out the email to China, HK domains.

                >so you relay mail for test.com.anydomain.example ?

                NO, relay the relative mails to the specific email address.

                >the .test.com entry is subject to parent_domain_matches_subdomain setting.
                Yes, I know this. thank you for your reminding.

                >> # vi /etc/postfix/transport
                >> /test\.com/                    dogz@...
                >no. this is a (risky) virtual alias entry. (it's risky because it breaks recipient validation).
                I know what you meant, but I just test by following what he said.

                >for transports, use something like (hash, not pcre here):
                >test.example            smtp:[earthquake.relay.example]:587
                what is the different if I use relay_domains map ? and I don't need to ask them to open the port.


                --
                Best Regards,
                Dogz
              • mouss
                ... http://en.wikipedia.org/wiki/Top-posting http://www.caliburn.nl/topposting.html ... I don t know what Magnus meant here. ... if this ISP supports
                Message 7 of 11 , Dec 30, 2006
                • 0 Attachment
                  Dogz wrote:
                  > Hi, Mouss,
                  >
                  >
                  >
                  > 2006/12/30, mouss <usebsd@...>:
                  >>
                  >> >>do not top post.
                  >
                  >
                  > I don't get it, I don't understand what you meant.

                  http://en.wikipedia.org/wiki/Top-posting
                  http://www.caliburn.nl/topposting.html
                  ...


                  >
                  >> If you know what domains to route where it's easy with the transport
                  >> table.
                  >> cn dogz.cn@...
                  >> hk dogz.hk@...
                  >> known-chinese-domain.example.com
                  > <http://known-chinese-domain.example.com/>
                  > dogs.cn@...
                  >

                  I don't know what Magnus meant here.

                  > In this case, we found the one of ISP can help us to relay it to send out
                  > emails to China, Hong Kong and so on. He just give us one email
                  > account to
                  > relay. Therefore we need to forward some domains belonged to China
                  > NIC, Hong
                  > Kong NIc and so on to this ISP, so that we can send out the email to
                  > China,
                  > HK domains.
                  >

                  if this ISP supports extensions, you can forward to
                  dogs.cn+user=domain@...
                  so that a later server can get the original address from here. This
                  assumes you have some control at the other end.

                  if he doesn't support extensions (but you still have some control at the
                  other end), you can play with the "To" header (aka multi-drop
                  mailboxes). but this is uggly and fragile.

                  The best would be if he accepts relaying from your network to some
                  domains (whatever is the user part).

                  >>
                  >> >so you relay mail for test.com.anydomain.example ?
                  >
                  >
                  > NO, relay the relative mails to the specific email address.


                  I meant that /test\.com/ matches any address that contains "test.com".
                  Including contest.company.com.

                  better use hash maps since you don't need pcre here.

                  >
                  >> the .test.com entry is subject to parent_domain_matches_subdomain
                  >> setting.
                  >
                  > Yes, I know this. thank you for your reminding.
                  >
                  >>> # vi /etc/postfix/transport
                  >> >> /test\.com/ dogz@...
                  >> >no. this is a (risky) virtual alias entry. (it's risky because it
                  >> breaks
                  >> recipient validation).
                  >> I know what you meant, but I just test by following what he said.
                  >>
                  >> >for transports, use something like (hash, not pcre here):
                  >> >test.example smtp:[earthquake.relay.example]:587
                  >> what is the different if I use relay_domains map ? and I don't need
                  >> to ask
                  >> them to open the port.
                  >>
                  >
                  >

                  relay_domains is just to declare which domains you accept to relay any
                  mail to.
                  if you don't need to open the port, just remove ":587" so that the
                  standard port is used.

                  but this assumes that the relay ISP accepts to relay any mail for you,
                  not just mail to "dogz".
                • Dogz
                  ... Thank you for your information. It seems that I can t use postfix to do that, or maybe it can, just can t find the way to do it. But I have done to build
                  Message 8 of 11 , Dec 30, 2006
                  • 0 Attachment

                    relay_domains is just to declare which domains you accept to relay any
                    mail to.
                    if you don't need to open the port, just remove ":587" so that the
                    standard port is used.

                    but this assumes that the relay ISP accepts to relay any mail for you,
                    not just mail to "dogz".


                    Hi,

                    Thank you for your information.
                    It seems that I can't use postfix to do that, or maybe it can, just can't find the way to do it.
                    But I have done to build another mail server in Windows platform for forwarding the mails to specific mail address, and my postfix server relays this server to send out the emails.

                    If you have any information can do that, please let me know it, because I don't want to waste a server to do that, especially in windows platform, although the undersea cables are recoverred soon.

                    Thank you for your nice reply.
                    Without your clarification, I thought my conception was wrong.

                    --
                    Best Regards,
                    Dogz
                  • mouss
                    ... if you describe what you did on windows, we ll tell you how to do it with postfix. ... If what you want is send mail for *@*.cn to dogz.cn@domain.example,
                    Message 9 of 11 , Dec 31, 2006
                    • 0 Attachment
                      Dogz wrote:
                      >
                      > Thank you for your information.
                      > It seems that I can't use postfix to do that, or maybe it can, just can't
                      > find the way to do it.
                      > But I have done to build another mail server in Windows platform for
                      > forwarding the mails to specific mail address, and my postfix server
                      > relays
                      > this server to send out the emails.

                      if you describe what you did on windows, we'll tell you how to do it
                      with postfix.
                      >
                      > If you have any information can do that, please let me know it, because I
                      > don't want to waste a server to do that, especially in windows platform,
                      > although the undersea cables are recoverred soon.

                      If what you want is send mail for *@*.cn to dogz.cn@..., then
                      a virtual alias like

                      /\.cn$/ dogz.cn@...

                      will do. But as said before

                      - the original recipient is lost from the envelope. It may still be in
                      the "To:" header (if it was there), but this is not always the case (for
                      instance, Bcc recipients won't be in the To header... etc).

                      - this breks recipient validation for all those of _your_ domains that
                      end in ".cn". If you have such domains, then you need to "fix" the
                      issue. one way is to have a special smtpd (with "its" cleanup) that
                      implements this virtual alias map (instead of implementing it on port 25).
                    • Dogz
                      ... Hi, There are several Mail server in windows platform, such like Mdaemon (sharware), hMailServer(GPL), they can do that. For example, run Mdaemon, click
                      Message 10 of 11 , Dec 31, 2006
                      • 0 Attachment
                        2006/12/31, mouss <usebsd@...>:
                        > Dogz wrote:
                        > >
                        > > Thank you for your information.
                        > > It seems that I can't use postfix to do that, or maybe it can, just can't
                        > > find the way to do it.
                        > > But I have done to build another mail server in Windows platform for
                        > > forwarding the mails to specific mail address, and my postfix server
                        > > relays
                        > > this server to send out the emails.
                        >
                        > if you describe what you did on windows, we'll tell you how to do it with postfix.

                        Hi,

                        There are several Mail server in windows platform, such like Mdaemon
                        (sharware), hMailServer(GPL), they can do that.
                        For example, run Mdaemon, click gateway, choose "new gateway", enter
                        the name of the domain and the directory where you want to store
                        incoming mail for the domain, then click "Forwarding" , checked
                        "Forward mail to this email address" and enter the email address.

                        > If what you want is send mail for *@*.cn to dogz.cn@..., then a virtual alias like
                        > /\.cn$/ dogz.cn@...
                        > will do. But as said before

                        I am not sure if I misunderstand what you said, it is showed "Relay
                        access denied"

                        I added "virtual_alias_maps = pcre:/etc/postfix/virtual_alias" into
                        main.cf, and create "/etc/postfix/virtual_alias" contained "/\.cn$/
                        kusoit@..."

                        and reload postfix, then test it from outside network.

                        I can't work it out.

                        Please advise me and thank you in advance.

                        --
                        Best Regards,
                        Dogz
                      • mouss
                        ... so if I understand, this is a virtual alias configuration. ... please provide enough infos: how you test it, what the logs say, ... etc. if you get relay
                        Message 11 of 11 , Jan 1, 2007
                        • 0 Attachment
                          Dogz wrote:
                          > 2006/12/31, mouss <usebsd@...>:
                          >> Dogz wrote:
                          >> >
                          >> > Thank you for your information.
                          >> > It seems that I can't use postfix to do that, or maybe it can, just
                          >> can't
                          >> > find the way to do it.
                          >> > But I have done to build another mail server in Windows platform for
                          >> > forwarding the mails to specific mail address, and my postfix server
                          >> > relays
                          >> > this server to send out the emails.
                          >>
                          >> if you describe what you did on windows, we'll tell you how to do it
                          >> with postfix.
                          >
                          > Hi,
                          >
                          > There are several Mail server in windows platform, such like Mdaemon
                          > (sharware), hMailServer(GPL), they can do that.
                          > For example, run Mdaemon, click gateway, choose "new gateway", enter
                          > the name of the domain and the directory where you want to store
                          > incoming mail for the domain, then click "Forwarding" , checked
                          > "Forward mail to this email address" and enter the email address.
                          >

                          so if I understand, this is a virtual alias configuration.


                          >> If what you want is send mail for *@*.cn to dogz.cn@...,
                          >> then a virtual alias like
                          >> /\.cn$/ dogz.cn@...
                          >> will do. But as said before
                          >
                          > I am not sure if I misunderstand what you said, it is showed "Relay
                          > access denied"
                          >
                          > I added "virtual_alias_maps = pcre:/etc/postfix/virtual_alias" into
                          > main.cf, and create "/etc/postfix/virtual_alias" contained "/\.cn$/
                          > kusoit@..."
                          >
                          > and reload postfix, then test it from outside network.

                          please provide enough infos: how you test it, what the logs say, ... etc.

                          if you get "relay access denied", then the domain is not in your relay
                          domains. so your postfix will not accept mail for this domain unless you
                          come from mynetworks (or you use auth or TLS, and configure these in
                          smtpd recipient restrictions)...
                        Your message has been successfully submitted and would be delivered to recipients shortly.