apr_socket_connect(): No connection could be made because the target machine actively refused it.

When the one of my local projects has been tested with an Apache HTTP server benchmarking tool (ab) I’ve got an error:

ab -c400 -n2000 http://localhost/myproject/

Test aborted after 10 failures.

apr_socket_connect(): No connection could be made because the target machine actively refused it. (730061)

I’ve tryed to configure httpd-mpm.conf the mpm_worker_module section but nothing changed. I’ve checked the mpm module that is using:

httpd -l

Compiled in modules:

mpm_winnt.c

So, my fault.. I’ve tryed to configure mpm_worker_module that isn’t used but the current mpm module that is used is mpm_winnt_module because I use XAMPP on Windows.

To fix this error you shoud set ThreadsPerChild with a bigger value and restart the web server.