I'm trying to load test/benchmark a http server with a very large number of simultaneous connections (10-100k). What is a good procedure for doing this? On linux I've seen that both the client and host likely need to have the number of permitted threads to be explicitly increased.

Also, does anyone have a good feel for how many client machines are needed for testing 10k and up connections? Is one machine enough, or does there tend to be a cap on the number of sockets a machine can handle?

I'm currently using nperf to generate loads. I've been successful up to around 1-2k concurrent requests, after which some of the requests come back failed. I'm not sure if the failures are of the server, or the client and I'm reluctant (lazy) to provision more machines for use as clients if the issue can be resolved with the one I have.

  • I think it would be helpful if you said which tools you use to generate the load. On the other hand, why don't you try a simple test and see how the load generators fare in terms of their own load (CPU, Errors, lag)?
    – asoundmove
    Nov 17, 2015 at 23:49
  • @asoundmove this question originally existed including a question about what tools to use for this task, but that's against the rules here. So technically I can't ask what tool would be good to use. Currently I'm using nperf (node http-perf). I have encountered errors using nperf, but I'm unable to tell if it's the tool or the server.
    – kag0
    Nov 17, 2015 at 23:54
  • Sorry I do not know this tool. It seems lightweight so it should be able to handle lots of connections - depending on your load generator specs (RAM, CPU). I have used load-runner (on Windows), a most probably much more resource-hungry platform with a couple of thousand simultaneous requests per minute.
    – asoundmove
    Nov 18, 2015 at 0:01

1 Answer 1


Without any more details about your set-up, I'm tempted to say that you need to try it out.

The best way to benchmark your load generators is to try an easy load on a very light test page on your server (something that is going to cause the least amount of load on the http server). This will test your set-up's ability to generate the load so you can decide how many generators you need. You'll need to monitor your generators particularly for CPU, network, and the timeliness of each request (i.e. are they all sent out to schedule or do they build-up and lag behind?). Check the error logs on your generators, check for dropped requests.

Then you can move on to your real test. Now for the real test you may need to adjust your load generators set-up, depending on how complex your test case is, but the benchmark above will give you a good starting point.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.