Page 1 of 1

how to allow pop3 from WAN1 and others from WAN 2

Posted: Mon Oct 07, 2019 1:33 pm
by hashmatfazly
Hello everyone

i need some help to configure my MikroTik RB to use WAN1 for (POP3) outlook only and the rest of usage should be from WAN 2.

Re: how to allow pop3 from WAN1 and others from WAN 2

Posted: Mon Oct 07, 2019 2:30 pm
by dmitris
If you want reach mail server outside you organization, you can use src-nat for this...
/ip firewall nat
add action=masquerade chain=srcnat disabled=no dst-port=25,587,465,110,995 \
    out-interface=WAN1 protocol=tcp
add action=masquerade chain=srcnat disabled=no src-address=YOUR-SUBNET-HERE  \
    out-interface=WAN2

Re: how to allow pop3 from WAN1 and others from WAN 2

Posted: Mon Oct 07, 2019 7:00 pm
by hashmatfazly
thanks worked only for outlook POP3 and SMTP. but for Microsoft exchange give error

Re: how to allow pop3 from WAN1 and others from WAN 2

Posted: Mon Oct 07, 2019 7:09 pm
by dmitris
try to add ...
dst-port=25,587,465,110,995,143,993

Re: how to allow pop3 from WAN1 and others from WAN 2

Posted: Mon Oct 07, 2019 7:59 pm
by anav
Hmm I did mine a little differently using IP routing.
WAN1 is primary (distance 2)
WAN2 is secondary (only used on failover) distance 10
However for all traffic with destination of IP address of email server,
(which smtp traffic resolves to via DNS) I have IP route rule that gives highest priority to secondary wan. distance 1

Not sure if that would be useful to you?