[root@NOTEBOOK ~] time for i in 128 321; do sleep 302; ab -n $i -c $i https://EXAMPLE.COM/ 2>/dev/null | egrep '^Complete requests:|^Failed requests:|^Requests per second:|^Time taken for tests:'; echo '______________________'; done
Time taken for tests: 87.538 seconds
Complete requests: 128
Failed requests: 0
Requests per second: 1.46 [#/sec] (mean)
______________________
Time taken for tests: 58.507 seconds
Complete requests: 321
Failed requests: 490
Requests per second: 5.49 [#/sec] (mean)
______________________
尋ねる:失敗した要求>完了した要求はどのように可能ですか?
ps:「Sleep 302」が必要です。なぜなら、abを多すぎると出力が100%失敗するからです。