> > If I have to set the VIP on dummy
> > or lo, then wouldn't I have to set a real, routable ip on eth0 so packets
can
> > get routed back to the internet?
>
> no. The packet coming from the realserver has src_addr=VIP
>
> Joe
Okay. If I don't have an ip on eth0 that's in the same network as the default
gw, how does the real server ever get the arp response from the gw?
This is what I did:
------------
| client |
------------
|
--------
| GW |
--------
| x.y.z.1
| ------------eth1
|-----------| director |--------
| eth0------------ |
| |
| -------------- |
--------------| realserver |----
eth0--------------eth1
=== On director ===
eth0 - x.y.z.1 netmask 255.255.255.0
eth0:0 - VIP netmask 255.255.255.0 (arps)
eth1 - 192.168.0.1 netmask 255.255.255.0
=== on realserver ===
dummy0 - VIP netmask 255.255.255.255 (no arp)
eth0 - 0 (no ip)
eth1 - 192.168.0.2 netmask 255.255.255.0
I then added the routes and the arp entry:
route add -net x.y.z.0 netmask 255.255.255.0 dev eth0
route add default gw x.y.z.1 dev eth0
arp -s x.y.z.1 MAC_OF_GW
This actually works, but the last bit about adding the routing and the arp entry
manually seems kind of hackish. Is this ok to do?
Thanks for all the responses btw. They have been a big help.
Dan
|