CentOS7对Apache+PHP 负载能力ab测试

分类:CentOS教程 阅读:82928 次

使用的系统信息:

  1. [root@localhost~]#uname-a
  2. Linuxlocalhost.localdomain3.15.4-x86_64-linode45#1SMPMonJul708:42:36EDT
  3. 2014x86_64x86_64x86_64GNU/Linux
  4. [root@localhost~]#php-v
  5. PHP5.4.16(cli)(built:Aug6201413:12:28)
  6. Copyright(c)1997-2013ThePHPGroup
  7. ZendEnginev2.4.0,Copyright(c)1998-2013ZendTechnologies
  8. [root@localhost~]#httpd-v
  9. Serverversion:Apache/2.4.6(CentOS)
  10. Serverbuilt:Jul23201414:48:00
  11. [root@localhost~]#

ab测试 phpinfo() 结果:吞吐量 759!

  1. D:\wamp\bin\apache\apache2.4.9\bin>ab-n100-c10http://linode.zbphp.com/
  2. ThisisApacheBench,Version2.3<$Revision:1554214$>
  3. Copyright1996AdamTwiss,ZeusTechnologyLtd,http://www.zeustech.net/
  4. LicensedtoTheApacheSoftwareFoundation,http://www.apache.org/
  5. Benchmarkinglinode.zbphp.com(bepatient).....done
  6. ServerSoftware:Apache/2.4.6
  7. ServerHostname:linode.zbphp.com
  8. ServerPort:80
  9. DocumentPath:/
  10. DocumentLength:52627bytes
  11. ConcurrencyLevel:10
  12. Timetakenfortests:7.592seconds
  13. Completerequests:100
  14. Failedrequests:14
  15. (Connect:0,Receive:0,Length:14,Exceptions:0)
  16. Totaltransferred:5280981bytes
  17. HTMLtransferred:5262681bytes
  18. Requestspersecond:13.17[#/sec](mean)
  19. Timeperrequest:759.206[ms](mean)
  20. Timeperrequest:75.921[ms](mean,acrossallconcurrentrequests)
  21. Transferrate:679.29[Kbytes/sec]received
  22. ConnectionTimes(ms)
  23. minmean[+/-sd]medianmax
  24. Connect:60734.77080
  25. Processing:208635101.4660690
  26. Waiting:70237120.5220640
  27. Total:279708101.5740770
  28. Percentageoftherequestsservedwithinacertaintime(ms)
  29. 50%740
  30. 66%740
  31. 75%740
  32. 80%745
  33. 90%750
  34. 95%760
  35. 98%760
  36. 99%770
  37. 100%770(longestrequest)
  38. D:\wamp\bin\apache\apache2.4.9\bin>