How to relay outgoing mails through another mailserver?

Discussion in 'Installation/Configuration' started by Benedict, Jun 8, 2022.

  1. Benedict

    Benedict Member HowtoForge Supporter

    This is about configuring the relay option in ispconfig (Relayhost) . I know examples from the howto section as well as the manual already. My intention is to relay email due to ip best reputation of some server. So that's the background: imagine servers A and B, B is relayhost. Therefore I configured A's main.cf.
    Code:
    mynetworks = 127.0.0.0/8 <ipv4 server B>  <ipv6 server B> [::1]/128
    And in B's ispconfig panel I filled the textfield Relayhost under System > Server Config Mail and set serverA.somedomain.tld
    Now a 'mailq' for server A shows
    Code:
    -Queue ID-  --Size-- ----Arrival Time---- -Sender/Recipient-------
    2F438C1ADF     2200 Wed Jun  8 09:02:37  [email protected]
                       (connect to 127.0.0.1[127.0.0.1]:10026: Connection refused)
                                             [email protected]
    What is wrong in your opinion and is it enought information to give some advice?
     
  2. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    spam / virus scanning.

    check clamav and amavis or rspamd are working.
     
  3. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    It is on A that you fill the Relayhost settings to use B as relayhost.
     
  4. Benedict

    Benedict Member HowtoForge Supporter

    Think of B as a web slave in a multiserver system an A is the mailserver. Then my scenario works for you? But my servers are two perfect servers. And they work just fine, seperatly
     
  5. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    I am just saying, that if you want to relay emails from host A to host B, then you enter the relayhost information on host A.
    Does B have also mail server installed and working?
     
  6. Benedict

    Benedict Member HowtoForge Supporter

    ok
    Yes
     
  7. Benedict

    Benedict Member HowtoForge Supporter

    Hello,
    the emails are going through now. Unfortunately I can't tell you why it works now. I don't see my mistake and would say that the configuration above is absolutely correct. It is also taken from the notes here in the forum and the manual. Anyway thanks.
     

Share This Page