Created
June 28, 2019 08:55
-
-
Save muzea/9046afc136b1717a113e5b430cef3aed to your computer and use it in GitHub Desktop.
nginx 测试
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM debian:9 | |
RUN apt update && apt install nginx apache2-utils -y |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ docker run --rm benchmark-test sh -c "/etc/init.d/nginx start && ab -c 500 -n 10000 http://127.0.0.1/" | |
Starting nginx: nginx. | |
This is ApacheBench, Version 2.3 <$Revision: 1757674 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking 127.0.0.1 (be patient) | |
Server Software: nginx/1.10.3 | |
Server Hostname: 127.0.0.1 | |
Server Port: 80 | |
Document Path: / | |
Document Length: 612 bytes | |
Concurrency Level: 500 | |
Time taken for tests: 1.040 seconds | |
Complete requests: 10000 | |
Failed requests: 0 | |
Total transferred: 8450000 bytes | |
HTML transferred: 6120000 bytes | |
Requests per second: 9616.32 [#/sec] (mean) | |
Time per request: 51.995 [ms] (mean) | |
Time per request: 0.104 [ms] (mean, across all concurrent requests) | |
Transfer rate: 7935.34 [Kbytes/sec] received | |
Connection Times (ms) | |
min mean[+/-sd] median max | |
Connect: 0 2 4.1 0 26 | |
Processing: 2 10 6.9 9 231 | |
Waiting: 1 10 6.8 9 231 | |
Total: 3 12 8.0 10 231 | |
Percentage of the requests served within a certain time (ms) | |
50% 10 | |
66% 12 | |
75% 13 | |
80% 14 | |
90% 19 | |
95% 24 | |
98% 28 | |
99% 30 | |
100% 231 (longest request) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment