I'm looking to set up the following:
---[IVR 1]
|
(internet)----[CentOS box]---+---[IVR 2]
|
---[IVR 3]
The CentOS box's internal interface is 192.168.110.1, and the IVRs' 192.168.110.101-103.
What I'm trying to do is to map a bunch of external UDP ports across to each IVR - so, for example, ports 10000-14999 are mapped to IVR 1, 15000-19999 to IVR 2, etc. The problem I have is that the ports must be mapped directly across - i.e. something coming in from the internet to port 10000 will be sent to port 10000 on IVR, and something coming being sent from port 10000 in IVR 1 will be sent out from port 10000 on the internet-facing interface of the CentOS box.
iptables' NAT stuff all comes with the caveat that it'll try not to remap ports, but may have to.
Right now, my options look like:
map ports individually (15,000 iptables lines, one for each port) of the form
ipables -t nat -A PREROUTING -i eth0 -p udp --dport 10000 -j DNAT --to 192.168.110.101:10000
build a kernel with the UDP conntrack timeouts turned right down
neither of which are terribly appealing.
What have I missed?