Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    2 iredmail mailservers behind haproxy

    Scheduled Pinned Locked Moved HA/CARP/VIPs
    2 Posts 2 Posters 487 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      Tony Soprano
      last edited by

      Hello all. i already have a quite big infrastructure.
      2 pfsense HW in failover ans sync.
      i want to create 2 new servers with 2 iredmail mailserver on them.
      What i want is HaProxy will redirect tcp requests from internet to one of the 2 mailserver in loadbalance failover roundrobin.
      i already did the frontend answering tcp 25,143,587 but these doesnt go to backend as expected.
      i did not NAT, just firewall rule on wan and haproxy front and backend
      Hope you'll help me
      thanks

      VioletDragonV 1 Reply Last reply Reply Quote 0
      • VioletDragonV
        VioletDragon @Tony Soprano
        last edited by

        @Tony-Soprano It is not very easy to Proxy SMTP and IMAP with Haproxy and will cause adnormal problems. But you would need to enable Proxy in Postfix main.cf.

        Personally I would not bother.

        I would use Haproxy for Webmail & ActiveSync on Port 443 then for SMTP 25. 587 and IMAP 993 I would put them under NAT instead.

        Depending how many Static IPs you have too.

        I would configure mx1 on Public IP 01 and mx2 on Public IP 02 then configure relay from mx2 to mx1. Make sure you have PTR Records added by your ISP too.

        Regards

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.