I am currently working on some Ajax heavy code and I am wondering how my server will scale as more and more users (hopefully) start to use my web app. It is only on my internal test server for the moment and I was wondering how I would go about simulating a few hundred or thousand users so that I can see how it handles a heavier load. It is written in PHP/MySQL and I really didn't want to find hundreds of computers to set up and test manually :) Thanks in advance, any advice or direction is much appreciated.
Apache Benchmark. It ships with Apache Web Server. Works kinda like this: For 100 requests using 10 concurrent threads, use this command:
ab -n 100 -c 10 http://localhost/
Replace the localhost url with a url that your AJAX code will be calling. The output will give you a nice report on how the requests were processed. Some of the interesting numbers are:
Complete requests
Failed requests
Requests per second
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With