Question

I want to see how far my nginx + node.js setup can go and what changes I can make to squeeze out extra performance I've stumbled on a great article detailing some tuning that can be done to the OS to withstand more requests (which I'm not sure I completely understand)

Say I want to see how it handles 60,000 requests per second for a duration of time.

I've tried apachebench and beeswithmachineguns. apachebench seems to be limited locally to about 3500 requests or something. Raising the concurrency only serves to decrease the average req/s somehow. I was able to see (claimed) ~5000 requests per second to a test page with beeswithmachineguns but that's still nowhere close to what I want. It seems to be a bit on the buggy side, however.

Is there a reliable way to simulate a huge amount of requests like this?

Was it helpful?

Solution

You could give siege a try as well.

The article you've linked looks good to me.

Generating 60,000 rq/s and answering them at the same time will be a problem because you most definitely run out of resources. It would be best to have some other computers (maybe on the same network) to generate the requests and let your server only handle answering those.

Here's an example siege configuration for your desired 60,000 rq/s that will hit your server for one minute.

# ~/.siegerc

logfile         = $(HOME)/siege.log
verbose         = true
csv             = true
logging         = true
protocol        = HTTP/1.1
chunked         = true
cache           = false
accept-encoding = gzip
benchmark       = true
concurrent      = 60000
connection      = close
delay           = 1
internet        = false
show-logfile    = true
time            = 1M
zero-data-ok    = false

If you don't have the infrastructure to generate the load, rent it. A very great service is Blitz.IO (I'm not affiliated with them). They have an easy and intuitive interface and (most important) they can generate nearly any traffic for you.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top