@orion777 wrote:
Due to network configuration I need to re-create the TCP connection with specific port, say, 5555, like:
source NIC 192.168.10.70 -> NAT server with proxy 192.168.10.1 - haproxy - 213.100.60.20 -> WAN destination server 213.100.70.30So, haproxy must listen port 5555 on eth0 192.168.10.1 and automatically redirect this TCP flow to 213.100.70.30:5555 over eth1 213.100.60.20.
The remaining traffic should be routed via typical NAT (shorewall) to be able to access the internet (this is optional, but desirable).To do this I was trying to make such haproxy.cfg
cat /etc/haproxy/haproxy.cfg
globaldaemon
maxconn 10
defaults
mode tcp
timeout connect 5000ms
timeout client 10000ms
timeout server 10000msfrontend tcp-in
bind 192.168.10.0:14550
default_backend serversbackend servers
server server1 213.100.70.30:5555 maxconn 32The haproxy has been started with such options:
haproxy -f /etc/haproxy/haproxy.cfg -V
The TCP connection nas been made from the source NIC 192.168.10.70 to 192.168.10.1:5555 , but the connection was not espablished wit the destination 213.100.70.30
Since I’m new, I’m asking for help. Thank you.
Posts: 2
Participants: 2