用keepalived做负载均衡,在测试中出现的关于连接数的问题?
章博士你好,有些问题想请教一下
基于keepalived配置的负载均衡已经可以在应用服务器之间实现调度和热备。
但是在测试中发现的问题:
1.我是用apache自带的ab工具进行测试 VIP:192.168.11.253
192.168.11.63是我用ab工具进行测试的机器
输入:.ab -c 1000 -n 10000 http://192.168.11.253/mains.php
调度服务器上显示如下:
IP Virtual Server version 1.2.1 (size=4096)
Prot LocalAddress:Port Scheduler Flags
-> RemoteAddress:Port Forward Weight ActiveConn InActConn
TCP 192.168.11.253:http rr
-> 192.168.11.70:http Route 100 0 2632
-> 192.168.11.69:http Route 60 0 2632
-> 192.168.11.251:http Route 40 0 2632
-> 192.168.11.252:http Route 10 0 2632
为什么会出现这种情况?
我看了一下应用服务器上在apache的日志里可以看到有差不多数量的连接过来 ,不清楚为什么会在Activeconn上都使0呢? 会是什么地方出现的问题?
我查看了一下:ipvsadm -lcn
TCP 01:51 FIN_WAIT 192.168.11.63:34932 192.168.11.253:80 192.168.11.251:80
TCP 01:51 FIN_WAIT 192.168.11.63:34281 192.168.11.253:80 192.168.11.252:80
TCP 01:55 FIN_WAIT 192.168.11.63:40847 192.168.11.253:80 192.168.11.252:80
TCP 01:55 FIN_WAIT 192.168.11.63:40791 192.168.11.253:80 192.168.11.252:80
TCP 01:52 FIN_WAIT 192.168.11.63:37533 192.168.11.253:80 192.168.11.252:80
TCP 01:54 FIN_WAIT 192.168.11.63:33751 192.168.11.253:80 192.168.11.69:80
TCP 01:53 FIN_WAIT 192.168.11.63:37860 192.168.11.253:80 192.168.11.251:80
TCP 01:52 FIN_WAIT 192.168.11.63:36027 192.168.11.253:80 192.168.11.69:80
TCP 01:50 FIN_WAIT 192.168.11.63:59151 192.168.11.253:80 192.168.11.251:80
TCP 01:53 FIN_WAIT 192.168.11.63:39100 192.168.11.253:80 192.168.11.251:80
怎么都是这种显示? 以前我测试的过程中还会出现ESTABLISH 但是现在只有FIN_WAIT?
对这个不了解,请高人指点。
2.现在还处于测试阶段,都需要知道哪些测试数据才能肯定我配置的系统是稳定的??
3.对与负载均衡的算法,rr和wrr我知道是实现了,但是我需要如何进行测试用例来验证其他算法??怎么看出来其他算法也是实现了。我知道在keepalived配置文件更改其他的算法名称就可以,但是我不知道如何压力测试在证明这个算法我的负载均衡使可以实现的??
请大家一起讨论
tony2002
周五, 2009-02-27 08:32
Permalink
我用ab测试的vip结果和rip结果差10倍,没找出瓶颈到底在那里阿?
环境:lbs:cent os 5.2 lvs 1.25 keepalived 1.1.5(6) GB SWITCH GB NIC
real server:rhel5.2,apache2.0.63
vip:10.0.0.2 rip:10.0.0.20,10.0.0.25
lvs DR RR
REAL SERVER TEST
./ab -c 1000 -n 10000 http://10.0.0.20:8080/images/logo.png
Requests per second: 5233.11 [#/sec] (mean)
Time per request: 191.091 [ms] (mean)
Time per request: 0.191 [ms] (mean, across all concurrent requests)
Transfer rate: 47260.18 [Kbytes/sec] received
./ab -c 1000 -n 10000 http://10.0.0.25:8080/images/logo.png
Requests per second: 4168.05 [#/sec] (mean)
Time per request: 239.920 [ms] (mean)
Time per request: 0.240 [ms] (mean, across all concurrent requests)
Transfer rate: 36730.53 [Kbytes/sec] received
VIP TEST
./ab -c 1000 -n 10000 http://10.0.0.2:8080/images/logo.png
Requests per second: 359.43 [#/sec] (mean)
Time per request: 2782.182 [ms] (mean)
Time per request: 2.782 [ms] (mean, across all concurrent requests)
Transfer rate: 3182.29 [Kbytes/sec] received
Anonymous (没有被验证)
周三, 2014-03-05 08:09
Permalink
TkLkfLjbIal
I thank you humbly for shirnag your wisdom JJWY
Anonymous (没有被验证)
周三, 2014-03-05 15:56
Permalink
oFeTmPsCSCQEGUpbIOYN
Inhsgits like this liven things up around here.
Anonymous (没有被验证)
周四, 2014-12-11 12:10
Permalink
AWHETEJHgXXCfZwvcNy
This is just the peefcrt answer for all forum members
Anonymous (没有被验证)
周一, 2014-05-19 07:49
Permalink
maDeBAlajbJBQLc
health insurance auto insurance quotes online healthcare insurance affordable car insurance senior whole life insurance
Anonymous (没有被验证)
周五, 2014-12-19 22:34
Permalink
VANkfDOwKbEir
I read your post and wiehsd I was good enough to write it
Anonymous (没有被验证)
周二, 2014-12-23 13:22
Permalink
YiFWhGKtlTkuErSMhkgE
Gosh, I wish I would have had that intormafion earlier!
Anonymous (没有被验证)
周五, 2014-12-26 04:12
Permalink
hbDpRyxHjWiI
abilify cheap
Anonymous (没有被验证)
周四, 2015-02-19 18:24
Permalink
cuhRmYMSePl
marketing consultant viagra levitra realize diagnosed generic viagra 25mg same stringent make car nj auto insurance claim supplements mold online viagra 25mg nitric oxide commences know cialis 25mg tragical disease
Anonymous (没有被验证)
周五, 2015-02-20 08:54
Permalink
YHBTJuGAKwLMqFB
life impotence-free cialis 25mg online erectile savings should quote auto insurance average admit online viagra 25mg excitement enjoying sex sildenafil numerous
Anonymous (没有被验证)
周五, 2015-02-20 14:18
Permalink
RcLjkeaecSbnWTAIpuBy
san levitra zenerect increases metabolism cialis 25mg on line impotency procedures used cialis 25mg data demonstrate
Anonymous (没有被验证)
周二, 2015-03-03 00:10
Permalink
QakUCUwoDR
uncontrolled blood order viagra online support cheap buy cialis on line erection involved auto insurance quotes individual circumstance citrulline buy viagra online person herb contains purchase viagra 25mg go
Anonymous (没有被验证)
周四, 2015-03-05 09:51
Permalink
XUfeLGxzYg
car insurance car insurance quotes buy viagra cialis online auto insurance
Anonymous (没有被验证)
周一, 2014-06-02 07:43
Permalink
mMElndMELoOVueBWsV
essay writing service research paper best grad school essay writing service write essay for me car insurance homeowners homeonwners insurance
Anonymous (没有被验证)
周四, 2014-11-06 16:16
Permalink
eEpsMtsgNJSgIkJKM
health insurance cna auto insurance buy viagraa online cheap cialis accutane buy online
Anonymous (没有被验证)
周四, 2014-12-11 12:09
Permalink
HplMcnCJvuBurIASg
I had no idea how to approach this benrfe-oow I'm locked and loaded.