My routing is working pretty well except that I'm having trouble with the
servers sending out ARP replies and bouncing the connections between routed
and direct.
I know the patches are supposed to squelch ARP replies from the servers for
loopback addresses (yes, they are all patched). Any ideas how to stop it?
Config:
DR with LocalNode on the first server. Second server has IP address of
222.133.104.139 (all IP addresses are random here).
VIP's of 222.133.104.{223-226} routed to both systems...
Works great, but the VIP's get arped between the two machines... Also, when I
was trying to use the second ethernet interface on the director/server to get
to the other server, all three interfaces would send out ARP's
(director/server: eth0, eth1, server2: eth0)....
How do you prevent ARP's??? Ideally you would be able to specify it with
ifconfig and I thought that the loopback wasn't supposed to cause an ARP reply
after the patches...
Kernel 2.2.13pre6 from Alan's directory on ftp.funet.fi with the
ipvs-0.8.3-2.2.12 patch applied... (2.2.12 crashed every 5 min for some
reason...)
To test I can put a permanent entry ARP entry in the test system but I Really
can't do that with the router, especially since I will want to failover.
Thanks!
sdw
#rc.ipvs_tundirector
#for virtual file server
#
echo -n "rc.ipvs_tundirector "
#
#echo "deleting any ipfwadm forwarding rules"
#/sbin/ipfwadm -Ff
#
#network setup
VS_NETWORK="222.133.104.0"
VS_NETMASK="255.255.255.0"
VS_BROADCAST="222.133.104.255"
VIP_ADDRESS="222.133.104.226"
VIP_DEVICE="eth0:10"
VS2_NETWORK="222.133.104.0"
VS2_NETMASK="255.255.255.0"
VS2_BROADCAST="222.133.104.255"
VIP2_ADDRESS="222.133.104.223"
VIP2_DEVICE="eth0:0"
VS3_NETWORK="222.133.104.0"
VS3_NETMASK="255.255.255.0"
VS3_BROADCAST="222.133.104.255"
VIP3_ADDRESS="222.133.104.224"
VIP3_DEVICE="eth0:1"
VS4_NETWORK="222.133.104.0"
VS4_NETMASK="255.255.255.0"
VS4_BROADCAST="222.133.104.255"
VIP4_ADDRESS="222.133.104.225"
VIP4_DEVICE="eth0:11"
#
#standard assignment of IP to outside world on Director
#uncomment if not already part of rc.inet1
#VS_ADDRESS="216.33.104.226
#VS_DEVICE="eth0:10"
#/sbin/ifconfig ${VS_DEVICE} ${VS_ADDRESS} broadcast $VS_BROADCAST up
#route add -net ${VS_NETWORK} netmask ${VS_NETMASK} dev ${VS_DEVICE}
#
#VIP link to servers
/sbin/ifconfig ${VIP_DEVICE} ${VIP_ADDRESS} netmask ${VS_NETMASK} \
broadcast ${VS_BROADCAST} up
route del -host ${VIP_ADDRESS}
route add -host ${VIP_ADDRESS} dev ${VIP_DEVICE}
/sbin/ifconfig ${VIP2_DEVICE} ${VIP2_ADDRESS} netmask ${VS_NETMASK} \
broadcast ${VS_BROADCAST} up
route del -host ${VIP2_ADDRESS}
route add -host ${VIP2_ADDRESS} dev ${VIP2_DEVICE}
/sbin/ifconfig ${VIP3_DEVICE} ${VIP3_ADDRESS} netmask ${VS_NETMASK} \
broadcast ${VS_BROADCAST} up
route del -host ${VIP3_ADDRESS}
route add -host ${VIP3_ADDRESS} dev ${VIP3_DEVICE}
/sbin/ifconfig ${VIP4_DEVICE} ${VIP4_ADDRESS} netmask ${VS_NETMASK} \
broadcast ${VS_BROADCAST} up
route del -host ${VIP4_ADDRESS}
route add -host ${VIP4_ADDRESS} dev ${VIP4_DEVICE}
#
#
/sbin/ipvsadm -L
ipvsadm -D -t ${VIP_ADDRESS}:80
ipvsadm -A -t ${VIP_ADDRESS}:80 -s wlc #rr, wrr, or wlc
ipvsadm -D -t ${VIP2_ADDRESS}:80
ipvsadm -A -t ${VIP2_ADDRESS}:80 -s wlc #rr, wrr, or wlc
ipvsadm -D -t ${VIP3_ADDRESS}:80
ipvsadm -A -t ${VIP3_ADDRESS}:80 -s wlc #rr, wrr, or wlc
ipvsadm -D -t ${VIP4_ADDRESS}:80
ipvsadm -A -t ${VIP4_ADDRESS}:80 -s wlc #rr, wrr, or wlc
#add servers and services
#
#SERVER1="10.1.1.6"
SERVER1="222.133.104.139"
#http to 222.133.104.226
/sbin/ipvsadm -a -t ${VIP_ADDRESS}:80 -r ${SERVER1} -g -w 1
/sbin/ipvsadm -a -t ${VIP2_ADDRESS}:80 -r ${SERVER1} -g -w 1
/sbin/ipvsadm -a -t ${VIP3_ADDRESS}:80 -r ${SERVER1} -g -w 1
/sbin/ipvsadm -a -t ${VIP4_ADDRESS}:80 -r ${SERVER1} -g -w 1
#SERVER2="10.1.1.5"
#http to 192.168.1.3 with weight of 2
#/sbin/ipvsadm -a -t ${VIP_ADDRESS}:80 -r ${SERVER2} -g -w 2
#Localhost
/sbin/ipvsadm -a -t ${VIP_ADDRESS}:80 -r 127.0.0.1 -g -w 1
/sbin/ipvsadm -a -t ${VIP2_ADDRESS}:80 -r 127.0.0.1 -g -w 1
/sbin/ipvsadm -a -t ${VIP3_ADDRESS}:80 -r 127.0.0.1 -g -w 1
/sbin/ipvsadm -a -t ${VIP4_ADDRESS}:80 -r 127.0.0.1 -g -w 1
#
#display current settings on exit
/sbin/ipvsadm
#
#---------rc.ipvs_tundirector----------------------
#!/bin/sh
#----------------------rc.ipvs_tunserver-----------------
echo -n "rc.ipvs_tunserver "
# network and VIP info
VS_BROADCAST="222.133.104.255"
VIP_NETMASK="255.255.255.255"
VIP_ADDRESS="222.133.104.226"
VIP_DEVICE="lo:0"
VIP2_ADDRESS="222.133.104.223"
VIP2_DEVICE="lo:1"
VIP3_ADDRESS="222.133.104.224"
VIP3_DEVICE="lo:2"
VIP4_ADDRESS="222.133.104.225"
VIP4_DEVICE="lo:3"
#
#install non-arping tunnel device on Server
ifconfig $VIP_DEVICE $VIP_ADDRESS netmask $VIP_NETMASK \
broadcast $VS_BROADCAST up
route del -host ${VIP_ADDRESS}
route add -host ${VIP_ADDRESS} dev ${VIP_DEVICE}
ifconfig $VIP2_DEVICE $VIP2_ADDRESS netmask $VIP_NETMASK \
broadcast $VS_BROADCAST up
route del -host ${VIP2_ADDRESS}
route add -host ${VIP2_ADDRESS} dev ${VIP_DEVICE}
ifconfig $VIP3_DEVICE $VIP3_ADDRESS netmask $VIP_NETMASK \
broadcast $VS_BROADCAST up
route del -host ${VIP3_ADDRESS}
route add -host ${VIP3_ADDRESS} dev ${VIP_DEVICE}
ifconfig $VIP4_DEVICE $VIP4_ADDRESS netmask $VIP_NETMASK \
broadcast $VS_BROADCAST up
route del -host ${VIP4_ADDRESS}
route add -host ${VIP4_ADDRESS} dev ${VIP_DEVICE}
#
#echo "LVS Notice: make sure you have a route to the client(s) "
#uncomment if not already handled by rc.inet1
#CLIENT_NETWORK="192.168.1.0"
#CLIENT_NETMASK="255.255.255.0"
#CLIENT_DEVICE="eth0:1"
#route add -net ${CLIENT_NETWORK} netmask ${CLIENT_NETMASK} dev ${CLIENT_DEVICE}
#
#----------------------rc.ipvs_tunserver-----------------
--
OptimaLogic - Finding Optimal Solutions Web/Crypto/OO/Unix/Comm/Video/DBMS
sdw@xxxxxxx Stephen D. Williams Senior Consultant/Architect http://sdw.st
43392 Wayside Cir,Ashburn,VA 20147-4622 703-724-0118W 703-995-0407Fax 5Jan1999
----------------------------------------------------------------------
LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
To unsubscribe, e-mail: lvs-users-unsubscribe@xxxxxxxxxxxxxxxxxxxxxx
For additional commands, e-mail: lvs-users-help@xxxxxxxxxxxxxxxxxxxxxx
|