Forward from one LVS instance to another?
Robin Bowes <[email protected]> Thu, 15 Jul 2010 02:05:22 +0100
| Newsgroups | gmane.linux.redhat.piranha |
|---|---|
| Message-ID | <[email protected]> |
Hi, I'm running pulse/LVS to balance http/https traffic. I have identical setups in two DCs (with different IPs, of course). DC A looks like this: TCP $IP_A:http -> a048:http -> a046:http -> a044:http And DC B is the same, with a different IP: TCP $IP_B:http -> b048:http -> b046:http -> b044:http I'm using Direct Routing, and have an iptables REDIRECT in the *nat chain on each of the real servers. In DC A: -A PREROUTING -p tcp --dst $IP_A -m multiport --dports 80 -j REDIRECT In DC B: -A PREROUTING -p tcp --dst $IP_B -m multiport --dports 80 -j REDIRECT This all works just fine. Now, DC B is currently the "live" DC but we are planning a cutover to DC A. One of the things that this will involve is changing DNS records to point at $IP_A instead of $IP_B. The DNS change will take a while to propagate so I want to forward traffic that hits $IP_B after the cutover to $IP_A. What I thought I'd do is to simply specify $IP_A as the only real server of the LBs in DC B, ie: TCP $IP_B:http -> $IP_A:http However, this doesn't seem to work. So, I thought about it some more and figured I'd have to add a REDIRECT with the address of the original IP, eg. in DC A -A PREROUTING -p tcp --dst $IP_B -m multiport --dports 80 -j REDIRECT This didn't seem to work either. So, at this point I'm stumped. Anyone got any ideas how to make this work? Is this sort of thing possible with Direct Routing? R.