Here's the problem I'm having and so far I'm not even sure what to search Google for. For simplicity, let's start with this LVS-DR setup:
For MySQL: VIP is 1.1.1.1, RS is 1.1.1.2
For HTTP: VIP is 1.1.1.1, RS is 1.1.1.3
Both RealServers have the VIP on lo:0, like:
auto lo:0 iface lo:0 inet static address 1.1.1.1 netmask 255.255.255.255 pre-up sysctl -w net.ipv4.conf.eth0.arp_ignore=1 pre-up sysctl -w net.ipv4.conf.eth0.arp_announce=2
My problem comes when I want to access the load-balanced MySQL service from the HTTP realserver. Trying to connect to 1.1.1.1 from 1.1.1.3 is just hitting the local loopback interface, on which MySQL isn't running of course.
Is there any way for this to be made workable? That is, is there a way to force traffic going to 1.1.1.1 out of RS 1.1.1.3 instead of just hitting the loopback 1.1.1.1 address on that particular VM?
The way my cluster is set up, this actually affects more than just this service pair, so a global solution is ideal, if this is even possible.
[link][10 comments]