Home > go-webserver-benchmark

go-webserver-benchmark

Go-webserver-benchmark is a project mainly written in GO and SHELL, it's free.

a personal benchmark project

This is benchmark for webserver

Introduction:

This is a personal project to get benchmark result of webserver. Comparing webserver following.

  • apache 2.2
  • python 2.7
  • golang fa6814569009+ tip

Condition:

On WindowsXP SP3, Intel(R) Core(TM)2 Duo, 2.66GHz, 1.96GB RAM, Get benchmark with following command.

apache

Run apache and do following:

C:\>ab -n 100 -c 10 http://localhost/helloworld.txt    > apache2-n.log
C:\>ab -n 100 -c 10 -k http://localhost/helloworld.txt > apache2-k.log

python

Run python/server.bat and do following:

C:\>ab -n 100 -c 10 http://localhost:8989/helloworld.txt    > python-n.log
C:\>ab -n 100 -c 10 -k http://localhost:8989/helloworld.txt > python-k.log

golang1

Compile and run golang/server.go and do following:

C:\>ab -n 100 -c 10 http://localhost:8888/helloworld.txt    > golang1-n.log
C:\>ab -n 100 -c 10 -k http://localhost:8888/helloworld.txt > golang1-k.log

golang2

Compile and run golang/server.go and do following:

C:\>set GOMAXPROCS=100
C:\>ab -n 100 -c 10 http://localhost:8888/helloworld.txt    > golang2-n.log
C:\>ab -n 100 -c 10 -k http://localhost:8888/helloworld.txt > golang2-k.log

Result:

See .log file.

Normal

Server Requests per second [#/sec] Log File
apache 2138.76 apache2-n.log
python 15.06 python-n.log
golang1 18.39 golang1-n.log
golang2 23.58 golang2-n.log

Keep Alive

Server Requests per second [#/sec] Log File
apache 2138.81 apache2-k.log
python 13.59 python-k.log
golang1 160.41 golang1-k.log
golang2 2153.59 golang2-k.log
Previous:ipbt