业务要上线,而且是面向大规模的群里,这里需要做一些压测,顺手用一台服务器做了AB压测,这里贴一些数据,后续在做PTS测试,因为着急赶项目,所以简要记录一些关键节点。
安装AB:yum -y install httpd-tools
ab -v 查看ab版本
ab –help
开始做简单的测试,对象网址:https://2020.sxnuoyun.com/area/#/map
ab -n100000 -c 1000 https://2020.sxnuoyun.com/area/#/map
返回结果:
Server Software:
Server Hostname: 2020.sxnuoyun.com
Server Port: 443
SSL/TLS Protocol: TLSv1/SSLv3,ECDHE-RSA-AES128-GCM-SHA256,2048,128
Document Path: /area/#/map
Document Length: 1911 bytes
Concurrency Level: 1000
Time taken for tests: 220.271 seconds
Complete requests: 100000
Failed requests: 0
Write errors: 0
Non-2xx responses: 100295
Total transferred: 207518204 bytes
HTML transferred: 191571299 bytes
Requests per second: 453.99 #/sec
Time per request: 2202.709 ms
Time per request: 2.203 [ms] (mean, across all concurrent requests)
Transfer rate: 920.02 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 20 1140 389.5 1093 6140
Processing: 7 1056 256.0 1065 4422
Waiting: 7 356 81.9 355 4087
Total: 29 2196 412.3 2161 7365
Percentage of the requests served within a certain time (ms)
50% 2161
66% 2173
75% 2188
80% 2475
90% 2516
95% 2533
98% 2565
99% 5084
100% 7365 (longest request)
效果还是可以的,回头等业务上线,怼上PTS看看效果:)