急!急!急,请博士解答关于LVS轮询时间问题
搭建了一个LVS虚拟服务器(AS4操作系统).两个real server(AS3操作系统). 用VS/DR方式实现~客户端虽然能连接到real server1,但需要等到60秒以后才能转接real server2服务器呢,每次转接时间都为60秒,我用的调度算法为RR! 按正常情况下应该是客户端每访问一次换一个服务器吗! 这是为什么呢,想了几天都没想明白呀,请博士尽快回复,感激不尽~~谢谢了
lvs vip:192.168.1.159 real server ip:192.168.1.223和224
我是这样配置:
1.lvs机器上需要进行如下配置:
在/etc/rc.local中添加:
/sbin/ifconfig lo:0 192.168.1.159 netmask 255.255.255.255 broadcast 192.168.1.159 up
/sbin/route add -host 192.168.1.159 dev lo:0
echo 1 > /proc/sys/net/ipv4/ip_forward
echo 1 >/proc/sys/net/ipv4/conf/default/send_redirects
echo 1 >/proc/sys/net/ipv4/conf/lo/send_redirects
/usr/src/ipvsadm-1.24/ipvsadm -C
/usr/src/ipvsadm-1.24/ipvsadm -A -t 192.168.1.159:443 -s rr
/usr/src/ipvsadm-1.24/ipvsadm -a -t 192.168.1.159:443 -r 192.168.1.223 -g -w 1
/usr/src/ipvsadm-1.24/ipvsadm -a -t 192.168.1.159:443 -r 192.168.1.224 -g -w 1
在/etc/sysctl.conf 需要添加:
net.ipv4.ip_forward = 0
net.ipv4.conf.all.send_redirects = 1
net.ipv4.conf.default.send_redirects = 1
net.ipv4.conf.eth0.send_redirects = 1
2.real server机器上需要进行如下配置:
在/etc/sysctl.conf 中需要添加:
net.ipv4.ip_forward = 0
net.ipv4.conf.lo.arp_ignore = 1
net.ipv4.conf.lo.arp_announce = 2
net.ipv4.conf.all.arp_ignore = 1
net.ipv4.conf.all.arp_announce = 2
在/etc/rc.local中添加:
echo 0 >/proc/sys/net/ipv4/ip_forward
/sbin/ifconfig lo:0 192.168.1.159 netmask 255.255.255.255 broadcast 192.168.1.159 up
/sbin/route add -host 192.168.1.159 dev lo:0
那里还有问题呢~头都大了!请帮帮忙吧
xuyufei20540
周日, 2009-11-22 10:39
Permalink
顶
同样的问题?你是怎么解决的?我也遇到了同样的问题?
why007
周四, 2011-10-27 09:29
Permalink
为什么在real
为什么在real server端需要与Director端一样配置以下内容呢???
在/etc/rc.local中添加:
/sbin/ifconfig lo:0 192.168.1.159 netmask 255.255.255.255 broadcast 192.168.1.159 up
/sbin/route add -host 192.168.1.159 dev lo:0
谢谢您的回复!!!
wallaces
周三, 2009-12-02 08:14
Permalink
就是同一IP连接等待时
就是同一IP连接等待时间转向另一个机器的嘛!~~ 特简单 就在
vi /etc/keepalived/keepalived.conf
# persistence_timeout 60
注释掉这句话就OK了, 挺郁闷的吧 呵呵
我自己搭建了一个测试环境你可以来试试
http://202.149.227.87
Anonymous (没有被验证)
周三, 2014-03-05 16:25
Permalink
HbJlTKxFXFsSDC
Clear, inmfeoativr, simple. Could I send you some e-hugs?
Anonymous (没有被验证)
周三, 2014-03-05 23:28
Permalink
kHQWNZSEVDyOBxRo
You saved me a lot of haslse just now.
Anonymous (没有被验证)
周五, 2014-05-30 22:29
Permalink
zfrDUOnnAnIJx
auto insurance online quote best website to get someone to write a paper for you buy insurance auto town car insurance
Anonymous (没有被验证)
周三, 2014-06-04 09:11
Permalink
qUaRqkeDOREv
car insurance quotes affordable car insurance in kentucky state employee discounts car insuracne rates car insurance quotes business insurance new york
Anonymous (没有被验证)
周日, 2014-10-26 12:46
Permalink
QOwlQdJkJqCDoFDkzIwp
life insurance define cheap car insurance Levitra online car insurance rate quote car insurance
Anonymous (没有被验证)
周五, 2014-11-14 12:21
Permalink
AGQlRyfBFLWiPXJor
car insurance online prescription cialis insurance arizona auto tadalafil online