Two ISP and NAT

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi folks,
 
I have 2 ISP Inet connections.
 
1 Inet I (eth0) use have used for everything (SMTP server, MASQ for local network)
I got the 2 INET (eth1)  and made some changes:
 
They both have MASQ:
    iptables -t nat -A POSTROUTING -o $EXTERNAL_INTERFACE_2 -j MASQUERADE (2 Inet)
    iptables -t nat -A POSTROUTING -o $EXTERNAL_INTERFACE_1 -j MASQUERADE (1 Inet)
 
I changed default route to eth1 and put some additional  route:
ip route rep default via ext_ip2 dev eth1
ip route add  1.2.3.4 via ext_ip1 (eth0)
 
And now I'm having a problem with my email server (Lotus Notes on Linux).
It can send emails via SMTP but cannot use encrypted Lotus connection and receive emails as well.
 
 iptables -t nat -A PREROUTING -i $EXTERNAL_INTERFACE_1 -p tcp -d $EXTERNALIP_1 --dport 25 \
                                  -j DNAT --to-destination 1.2.3.196:25
 
# Lotus Notes Encrypted connection (tcp 1352) port forward from eth0 to internal ip 10.105.105.196 
 iptables -t nat -A PREROUTING -i $EXTERNAL_INTERFACE_1 -p tcp -d $EXTERNALIP_1 --dport 1352 \
                                   -j DNAT --to-destination 1.2.3.196:1352
 
And how to route with ip route command that email server have to use not the default route (eth1) but eth0.
 
What I need to configure more to get working back my email server?
 
 
Thank you in advance
 
Rimas
 

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux