Menu

#4 KeepAliveD with Internal Private IP NAT

open
nobody
None
5
2011-08-11
2011-08-11
Luis
No

Hey guys, i have been bashing my head in for 2 days so far. looked everywhere and no solutions or even an answer to see if it can be done.

I am setting up some LBing on an internal network i have.

192.168.1.9 = web server
192.168.1.10 = web server

I created a VIP using keepalived with a real and sorry server. VIP = 192.168.1.11

I can ping etc.

the 2 Keepalived boxes i have are as followed
192.168.1.252 = Primary Server
192.168.1.253 = backup

192.168.1.254 = VIP GW for all internal servers

Now heres the catch, i have IPTables installed on both servers.

i setup a INPUT rule, and Fwd rule AND NAT saying if example client machine 192.168.1.58 (RDP machine) tries to hit 192.168.1.11 = VIP then use the 192.168.1.254 GW to communicate.

can i do this?
i can see in a TCPdump the client machine hitting the VIP no issue, but then it tries to communicate directly with the Real server 192.168.1.9 .. i am not get any dropped rules from IPtables log, and my tcpdump is showing what i just mentioned. can IPtables and Keepalived do this?

i have it working JUST FINE with external public IP's and internal keepalived so ex: public IP (dum ip for now) 209.22.1.11 = VIP and real and sorry server. etc. that works. my iptables and rules work fine and it can be accessed from the outside . any help would be gladly appreciated.

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.