-p 超过600 ,http_load报的大量的以下错误:
服务器是8核cpu,worker 数 8到64都配过,测试端和服务器的网络延迟在0.2毫秒
内核配置:
net.ipv4.conf.all.accept_redirects = 0
net.ipv4.conf.default.accept_redirects = 0
net.ipv4.conf.all.send_redirects = 0
net.ipv4.conf.default.send_redirects = 0
net.ipv4.conf.default.arp_ignore = 1
net.ipv4.conf.default.arp_announce = 2
net.ipv4.conf.all.arp_ignore = 1
net.ipv4.conf.all.arp_announce = 2
net.ipv4.ip_no_pmtu_disc = 1
net.ipv4.tcp_max_syn_backlog = 65536
net.core.netdev_max_backlog = 32768
net.core.somaxconn = 32768
net.core.wmem_default = 8388608
net.core.rmem_default = 8388608
net.core.rmem_max = 16777216
net.core.wmem_max = 16777216
net.ipv4.tcp_synack_retries = 1
net.ipv4.tcp_syn_retries = 1
net.ipv4.tcp_tw_recycle = 1
net.ipv4.tcp_tw_reuse = 1
net.ipv4.tcp_timestamps = 0
net.ipv4.tcp_mem = 94500000 915000000 927000000
net.ipv4.tcp_max_orphans = 3276800
net.ipv4.tcp_fin_timeout = 1
net.ipv4.tcp_keepalive_time = 30
net.ipv4.tcp_max_tw_buckets = 6000
net.ipv4.ip_local_port_range = 1024 65535
在没有加 net.ipv4.tcp_max_tw_buckets = 6000 时,TIME_WAIT 数达到6万多,最终系统的qps为 32000/s(只有计算逻辑,没有io操作),而cpu占用只打达到70% 再增加客户端测试,就报:
而总的qps还是32000左右,cpu占用仍然是70%
在 2012年6月7日 下午8:25,agentzh
<age...@gmail.com>写道:
> 我用了多台服务器,加压,也就压到70%,再增加服务器,就报错了,
刚才看得太快了,没看到这一句,呵呵。你再增加测试客户端服务器时报什么错呢?这个信息很关键,呵呵。