i have something quite simple: I have one host with an ipaddress and one NIC.
now I would like that certain ports of that machine (25/80/110/143/443)
would be redirected to some other machine, because that one is replacing
the other, and I do not wish that there is any interruption in traffic.
so machine A has: 188.8.131.52 and one NIC
and machine B has: 184.108.40.206 and one NIC.
now i'm reading things like:
iptables -t nat -A PREROUTING -d 220.127.116.11 -p tcp \
--dport 80 -j DNAT --to-destination 18.104.22.168
which doesn't work.
what does work is something like:
iptables -t nat -A OUTPUT -d 22.214.171.124 -j DNAT --to \
but thats only for traffic which comes from the host itself, not for
foreign traffic that is going to the host.
hope someone can help.
Perhaps you should add a rule in FORWARD chain...